Link to home
Start Free TrialLog in
Avatar of ts84zs
ts84zs

asked on

check if browser is on mobile device using javascript

i have to write a javascript/html5 website. I have to check if the client browser is opened on a mobile device (like ipad , iphone, android etc)
how can i do that using javascript? pl guide...
thanks a lot
ASKER CERTIFIED SOLUTION
Avatar of Duy Pham
Duy Pham
Flag of Viet Nam image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ts84zs
ts84zs

ASKER

OK thanks a lot....

That javascript code works for all the browsers?
Yes, I believe it should work for most common mobile browsers. There might be some small mobile manufacturers making their own mobile browsers, but we don't really need to care about those until their devices have bigger market shares.
Avatar of ts84zs

ASKER

thanks a lot