
Yii2-mobiledetect (Определение мобильных устройств)
skeeks/yii2-mobile-detect
Yii2-mobiledetect (Определение мобильных устройств) В основе расширения, лежит использование общеизвестной библиотеки http://mobiledetect.net/
-
Семенов Александр
- /
- Autre
- /
- il y a 8 ans
- /
- /
- 11740
- /
- 0
Heure de publication: mardi 30 juin 2015 (il y a 8 ans)
Créé par: Семенов Александр Сергеевич
Catégorie: Autre
Version actuelle:
1 janv. 1970 à 03:00:00 (il y a 53 ans)
Packagist: skeeks/yii2-mobile-detect
: https://github.com/skeeks-semenov/yii2-mobile-detect
:
Type: Компонент
Yii2-mobiledetect (Определение мобильных устройств) В основе расширения, лежит использование общеизвестной библиотеки http://mobiledetect.net/
Mobile Detect extension for Yii2
This extension provides an Yii2 component wrapper for Mobile_Detect PHP class and can be used to detect whether a device is mobile one in your Yii2 application.
Installation
The preferred way to install this extension is through Composer.
Either run
php composer.phar require --prefer-dist skeeks/yii2-mobile-detect
or add
"skeeks/yii2-mobile-detect": "^1.0.2"
to the require
section of your composer.json
file.
Usage
Add
mobileDetect
component to your Yii2 configuration like this:'components' => [ 'mobileDetect' => [ 'class' => '\skeeks\yii2\mobiledetect\MobileDetect' ] ]
Use
mobileDetect
component as Mobile_Detect PHP class:echo \Yii::$app->mobileDetect->isMobile(); echo \Yii::$app->mobileDetect->isTablet(); echo \Yii::$app->mobileDetect->isDesctop();
//version >= 1.0.1 echo \skeeks\yii2\mobiledetect\MobileDetect::getInstance()->isMobile();
SkeekS CMS (Yii2) — quickly, easily and effectively!
skeeks.com | cms.skeeks.com
Процесс разработки
1.0.2
- Add properties isMobile isDesktop isTablet
- Fixed https://github.com/skeeks-semenov/yii2-mobile-detect/issues/1
1.0.1
- Добавлен новый метод \skeeks\yii2\mobiledetect\MobileDetect::getInstance()
- Исправлена кодировка файлов на utf-8
1.0.0
- Начало
dev-master — 1 janv. 1970 à 03:00:00 (il y a 53 ans)
1.0.2 — 1 janv. 1970 à 03:00:00 (il y a 53 ans)
1.0.1 — 1 janv. 1970 à 03:00:00 (il y a 53 ans)
1.0.0 — 1 janv. 1970 à 03:00:00 (il y a 53 ans)
Стандартная установка:
Добавьте composer.json файл вашего проекта:
"skeeks/yii2-mobile-detect": "*"
Запустите обновление зависимостей
Tous les commentaires (0)