Php mobile detect
Collapse
X
-
whats for use this?
Originally posted by tkreturns View PostPHP SCRIPT TO DETECT MOBILE
I AM NOT THE AUTHOR. DONT FORGET TO CLICK THANKS.
Usage
Include and instantiate the class:
Check for a specific platform:PHP Code:include("Mobile_Detect.php"); $detect = new Mobile_Detect();
Other case insensitive available methods are isIphone(), isIpad(), isBlackBerry(), isKindle(), isOpera(), etc. For the full list of available methods check the demo.php.PHP Code:if($detect->isiOS()){ // code to run for the Apple iOS platform. } if($detect->isAndroidOS()){ // code to run for the Google Android platform. }
Alternatively, if you are only interested in checking to see if the user is using a mobile device, without caring for specific platform:
PHP Code:if ($detect->isMobile()) { // any mobile platform } if($detect->isTablet()){ // any tablet }
PHP Code:Details Use isMobile() for detecting any kind of mobile device Use isTablet() for detecting tablet devices Test your device online at http://is.gd/mobiletest Further detection You can detect specific devices by using case-insensitive pseudo-methods. Phones isiPhone() isBlackBerry() isHTC() isNexus() isDellStreak() isMotorola() isSamsung() isSony() isAsus() isPalm() isGenericPhone() Tablets isBlackBerryTablet() isiPad() isKindle() isSamsungTablet() isHTCtablet() isMotorolaTablet() isAsusTablet() isNookTablet() isAcerTablet() isYarvikTablet() isGenericTablet() Operating systems isAndroidOS() isBlackBerryOS() isPalmOS() isSymbianOS() isWindowsMobileOS() isiOS() isFlashLiteOS() isJavaOS() isNokiaOS() iswebOS() isbadaOS() isBREWOS() Mobile browsers isChrome() isDolfin() isOpera() isSkyfire() isIE() isFirefox() isBolt() isTeaShark() isBlazer() isSafari() isMidori() isGenericBrowser()
cani use this for download site??? or chat community site(lavalair, retrivewap). and ow to do it?
Leave a comment:
-
more about the script here php-mobile-detect - PHP class for mobile device detection - Google Project Hosting
this is good in targetting specific traffic in conjuction with IP to location
Leave a comment:
-
Php mobile detect
PHP SCRIPT TO DETECT MOBILE
I AM NOT THE AUTHOR. DONT FORGET TO CLICK THANKS.
Usage
Include and instantiate the class:
Check for a specific platform:PHP Code:include("Mobile_Detect.php"); $detect = new Mobile_Detect();
Other case insensitive available methods are isIphone(), isIpad(), isBlackBerry(), isKindle(), isOpera(), etc. For the full list of available methods check the demo.php.PHP Code:if($detect->isiOS()){ // code to run for the Apple iOS platform. } if($detect->isAndroidOS()){ // code to run for the Google Android platform. }
Alternatively, if you are only interested in checking to see if the user is using a mobile device, without caring for specific platform:
PHP Code:if ($detect->isMobile()) { // any mobile platform } if($detect->isTablet()){ // any tablet }
PHP Code:Details Use isMobile() for detecting any kind of mobile device Use isTablet() for detecting tablet devices Test your device online at http://is.gd/mobiletest Further detection You can detect specific devices by using case-insensitive pseudo-methods. Phones isiPhone() isBlackBerry() isHTC() isNexus() isDellStreak() isMotorola() isSamsung() isSony() isAsus() isPalm() isGenericPhone() Tablets isBlackBerryTablet() isiPad() isKindle() isSamsungTablet() isHTCtablet() isMotorolaTablet() isAsusTablet() isNookTablet() isAcerTablet() isYarvikTablet() isGenericTablet() Operating systems isAndroidOS() isBlackBerryOS() isPalmOS() isSymbianOS() isWindowsMobileOS() isiOS() isFlashLiteOS() isJavaOS() isNokiaOS() iswebOS() isbadaOS() isBREWOS() Mobile browsers isChrome() isDolfin() isOpera() isSkyfire() isIE() isFirefox() isBolt() isTeaShark() isBlazer() isSafari() isMidori() isGenericBrowser()Attached FilesLast edited by tkreturns; 12.09.12, 11:28.Tags: None
Leave a comment: