In the past year I have developed a few mobile websites. These normally consist of a specific mobile view (jquerymobile) or a responsive design. In the case of a specific mobile view, you need some type of mechanism to detect the type of browser that is viewing the site. Because of the ever increasing mobile browsers and devices this is a tricky process. A few sites I created over 2 years ago do not register newer devices (kindle fire, newer androids, etc…)
I recently have decided to use MobileESP as the process to detect and interrogate what type of browser is viewing the site.
MobileESP has a few great options that I believe make it the best option.
First, they have multiple versions available. A real-time API and also a downloadable version. The realtime API takes into account the ever changing mobile landscape. This option would allow the developer to just have to focus on the action needed with a mobile or tablet like device and not worry about maintaining the list of devices.
window.location = "http://www.somemobilesite/m";
Here is the About info for the mobileESP project. The code is hosted on code.google.com
The MobileESP project seeks to provide web site developers an easy-to-use and lightweight API for detecting whether visitors are using a mobile device, and if so, what kind. The APIs provide simple boolean results (“true” or “false”) for identifying individual device categories (such as iPhone, BlackBerry, Android, and Windows Mobile), device capabilities (e.g., J2ME), and broad classes of devices, such as “iPhone Tier” (iPhone/Android/WebOS) and smartphones.
I would like to thank the great team who maintains and updates this project.