This bundle adds support for detect mobile devices. It uses the lightweight PHP class Mobile_Detect.
First add the dependency to your composer.json` file:
"require": {
...
"raindrop/mobiledetect-bundle": "dev-master"
},
Then install the bundle with the command:
php composer.phar update
Enable the bundle in your application kernel:
<?php
// app/AppKernel.php
public function registerBundles()
{
$bundles = array(
// ...
new Raindrop\MobileDetectBundle\RaindropMobileDetectBundle(),
);
}
Now the bundle is enabled.