Compatibility/UADetectionLibraries
Jump to navigation
Jump to search
User Agent Detection Libraries
This is a list of User Agent detection libraries to be tested for compatibility with Firefox OS and Firefox for Android. This may also include general purpose JS libraries that include some kind of UA detection.
The end goal is to contact these sites or (even better, in the case of open source libraries) provide patches so our mobile browsers are correctly identified as mobile (and not served desktop content or blocked outright).
UA strings to test with:
Firefox Mobile for Android:
Mozilla/5.0 (Android; Mobile; rv:23.0) Gecko/23.0 Firefox/23.0
Firefox OS:
Mozilla/5.0 (Mobile; rv:18.0) Gecko/18.0 Firefox/18.0
Libraries to be tested
JavaScript
- Device.js https://github.com/matthewhudson/device.js
- Dojo Toolkit https://github.com/dojo/ (see http://dojotoolkit.org/reference-guide/1.7/quickstart/browser-sniffing.html)
- Do we need to recommend a ffos or fxos token be added to the module? https://github.com/dojo/dojo/blob/master/sniff.js
- jQuery Mobile http://jquerymobile.com (FF for Android listed as A-grade support, FFOS not mentioned).
- Mootools (https://github.com/mootools/mootools-core/blob/master/Source/Browser/Browser.js)
Perl
- HTTP::BrowserDetect https://github.com/oalders/http-browserdetect
PHP
- Detector (Drupal) https://drupal.org/project/detector
- Mobile-Detect https://github.com/serbanghita/Mobile-Detect / http://mobiledetect.net/
- PHP Mobile Detect http://code.google.com/p/php-mobile-detect/
- PHP User Agent https://github.com/ornicar/php-user-agent
- PHP User Agent Parser https://github.com/donatj/PhpUserAgent
- PHP User Agent Parser https://bitbucket.org/hkgoldenmra/php-user-agent-parser
- Mobile Detect Bundle https://github.com/suncat2000/MobileDetectBundle
- WordPress Mobile Detect http://wordpress.org/plugins/wp-mobile-detect/
- Categorizr https://github.com/bjankord/Categorizr
Python
- Python User Agents https://github.com/selwin/python-user-agents
- Django Mobile https://github.com/gregmuellegger/django-mobile
- minidetector https://github.com/saschwarz/minidetector/network
- GoMobile (Plone) https://pypi.python.org/pypi/gomobile.mobile
Ruby
- user-agent https://github.com/visionmedia/user-agent/network
- note: TJ's lib is unmaintained but there appears to be a number of active forks.
- agent_orange https://github.com/kevinelliott/agent_orange
- browser https://github.com/fnando/browser
- Mobvious https://github.com/jistr/mobvious
- UserAgent https://github.com/josh/useragent
Server Modules
- Apache Mobile Filter http://www.apachemobilefilter.org/
- (NGINX has a DeviceAtlas module)
- Detect Right http://detectright.com/
- NetBiscuits http://www.netbiscuits.com/
- OpenDDR http://openddr.org/
Tested, issues reported in Bugzilla
Meta Bug: 915706
- http://detectmobilebrowsers.com/ Bug 914241*
- is-mobile Bug 914231
- Platform.js Bug 913633
- UA.js Bug 913189 *
- User Agent Utils 915727
- Woothee Bug 914313 *
- WPTouch (WordPress) Bug 909420
*fixed
Libraries known to be compatibile
Go
- UserAgent https://github.com/mssola/user_agent
Java
- UADetector https://github.com/before/uadetector
JavaScript
- Detect.js https://github.com/darcyclarke/Detect.js
- Express Device https://npmjs.org/package/express-device
- isMobile https://github.com/kaimallea/isMobile
- Mobile Agent https://github.com/fabdrol/mobileagent
- Node User Agent Parse https://github.com/jujhars13/node-user-agent-parse
- ua-parser-js https://github.com/faisalman/ua-parser-js
- useragent https://github.com/3rd-Eden/useragent
- YUI - http://yuilibrary.com/yui/docs/yui/yui-ua.html
Multiple Languages
- ua-parser (multiple languages) https://github.com/tobie/ua-parser
Server Detection Frameworks
- 51 Degrees http://51degrees.mobi/Products/DeviceDetection.aspx
- Device Atlas https://deviceatlas.com/device-data/user-agent-tester (it recognizes us as FFOS, but some of the data isn't quite accurate (says we dont support geolocation) and has some oddities like isBrowser: False (?)
- WURFL (1.4) http://tools.scientiamobile.com/?user-agent-string=Mozilla%2F5.0+%28Mobile%3B+rv%3A18.0%29+Gecko%2F18.0+Firefox%2F18.0