HI everybody, I'm newbie to ruby. I want to get user's browser and OS information like getting ip address using request.remote_ip. Is it possible. Regards, Veeraa.
on 2007-04-26 00:19
on 2007-04-26 00:36
request.env["HTTP_USER_AGENT"] Cheers, Ganesh Gunasegaran.
on 2007-04-26 02:57
Ganesh Gunasegaran wrote: > request.env["HTTP_USER_AGENT"] > > Cheers, > Ganesh Gunasegaran. Hello sir! Thank you very much for your prompt reply . Regards, Veeraa.
on 2007-04-26 03:50
Hi, I have one more doubt, here i want split the browser and OS information. But using split function is not good one. Any other way. Regards, W3matter.
on 2007-04-26 12:10
Veera Sundaravel <email@example.com> writes: > HI everybody, > > I'm newbie to ruby. I want to get user's browser and OS information like > getting ip address using request.remote_ip. Is it possible. > > Regards, > Veeraa. > > -- This information is part of the standard 'agent' information passed by browsers as an environment variable (well accessible as an environment variable). However, note that this information cannot be trusted (ie. its easy to fake and some browsers actually provide ways of faking it). How you actually access this information depends on whether your using a ruby library or just reading the data from stdin from the server etc. Most libraries provide an ENV hash or object that you can query. Tim
on 2007-04-26 13:06