Motto: "Every business should have a mobile detection script to detect mobile readers."
Forking the project
- Clone the repository
https://github.com/serbanghita/Mobile-Detect.git
to your local drive. - Switch to
devel
branch. - Commit your changes to
Mobile_Detect.php
or whatever file. - Commit tests (User-Agent strings) to
tests/UA_List.inc.php
. It's important to put tests in if you change the regexes, otherwise the commit will not pass. - Run the tests
php phpunit.phar /path/to/mobiledetectlib/tests/phpunit.xml
. Check for errors. - Run the code fix
php php-cs-fixer.phar fix "/path/to/mobiledetectlib" --verbose --dry-run
. If there are errors run it again without--dry-run
. - Commit to
devel
. Push. - The commit will be reviewed and merged into
master
2.9.9 version | Work scheduled on the 2.x.x branch (currently in production). |
3.0.0 version | Work scheduled on the 3.x.x branch. The new 3.0.0 version will feature: compatibility with 2.x , array with devices details (including model name), device/os/browser version, browser grading utility, separate JSON regex. |