Email This Post Email This Post Print This Post Print This Post

Moble Phone Detection

Fri, Sep 5, 2008 – 9:30 pm

Every moble phone script detection that I have run across (server side or client side) all seem to want to check user agent against a long long long long long list of values.

What’s wrong with simply checking screen width ? In my opinion there is a 99% probability that anything with a width of 640 or under is a mobile device.

Sure this will not tell anything about the capabilites of the browser (CSS/JavaScript/ect support) - but knowing it’s a cell phone would certainly give you a chance to know you have a low bandwidth device with a small screen - so don’t make them download your 1024×100 jpg page banner or the 1024×764 full page photos of your pet dog.

Post a Comment

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word