BNL Home

Device Detection

GitHub Repository | Website

Requirement

You must have a reference to the following include file at the top of your page:

require $_SERVER['DOCUMENT_ROOT'] . "/common/templates/global/scripts/mobile-detect.php";

Then, simply store the object is a PHP variable:

$detect = new Mobile_Detect;


Results

This is a computer.

Your User Agent (UA) is:
Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)


Supported Methods

Basic detection methods
isMobile()bool(false)
isTablet()bool(false)
Custom detection methods
isiPhone() bool(false)
isBlackBerry() bool(false)
isHTC() bool(false)
isNexus() bool(false)
isDell() bool(false)
isMotorola() bool(false)
isSamsung() bool(false)
isLG() bool(false)
isSony() bool(false)
isAsus() bool(false)
isNokiaLumia() bool(false)
isMicromax() bool(false)
isPalm() bool(false)
isVertu() bool(false)
isPantech() bool(false)
isFly() bool(false)
isWiko() bool(false)
isiMobile() bool(false)
isSimValley() bool(false)
isWolfgang() bool(false)
isAlcatel() bool(false)
isNintendo() bool(false)
isAmoi() bool(false)
isINQ() bool(false)
isOnePlus() bool(false)
isGenericPhone() bool(false)
isiPad() bool(false)
isNexusTablet() bool(false)
isGoogleTablet() bool(false)
isSamsungTablet() bool(false)
isKindle() bool(false)
isSurfaceTablet() bool(false)
isHPTablet() bool(false)
isAsusTablet() bool(false)
isBlackBerryTablet() bool(false)
isHTCtablet() bool(false)
isMotorolaTablet() bool(false)
isNookTablet() bool(false)
isAcerTablet() bool(false)
isToshibaTablet() bool(false)
isLGTablet() bool(false)
isFujitsuTablet() bool(false)
isPrestigioTablet() bool(false)
isLenovoTablet() bool(false)
isDellTablet() bool(false)
isYarvikTablet() bool(false)
isMedionTablet() bool(false)
isArnovaTablet() bool(false)
isIntensoTablet() bool(false)
isIRUTablet() bool(false)
isMegafonTablet() bool(false)
isEbodaTablet() bool(false)
isAllViewTablet() bool(false)
isArchosTablet() bool(false)
isAinolTablet() bool(false)
isNokiaLumiaTablet() bool(false)
isSonyTablet() bool(false)
isPhilipsTablet() bool(false)
isCubeTablet() bool(false)
isCobyTablet() bool(false)
isMIDTablet() bool(false)
isMSITablet() bool(false)
isSMiTTablet() bool(false)
isRockChipTablet() bool(false)
isFlyTablet() bool(false)
isbqTablet() bool(false)
isHuaweiTablet() bool(false)
isNecTablet() bool(false)
isPantechTablet() bool(false)
isBronchoTablet() bool(false)
isVersusTablet() bool(false)
isZyncTablet() bool(false)
isPositivoTablet() bool(false)
isNabiTablet() bool(false)
isKoboTablet() bool(false)
isDanewTablet() bool(false)
isTexetTablet() bool(false)
isPlaystationTablet() bool(false)
isTrekstorTablet() bool(false)
isPyleAudioTablet() bool(false)
isAdvanTablet() bool(false)
isDanyTechTablet() bool(false)
isGalapadTablet() bool(false)
isMicromaxTablet() bool(false)
isKarbonnTablet() bool(false)
isAllFineTablet() bool(false)
isPROSCANTablet() bool(false)
isYONESTablet() bool(false)
isChangJiaTablet() bool(false)
isGUTablet() bool(false)
isPointOfViewTablet() bool(false)
isOvermaxTablet() bool(false)
isHCLTablet() bool(false)
isDPSTablet() bool(false)
isVistureTablet() bool(false)
isCrestaTablet() bool(false)
isMediatekTablet() bool(false)
isConcordeTablet() bool(false)
isGoCleverTablet() bool(false)
isModecomTablet() bool(false)
isVoninoTablet() bool(false)
isECSTablet() bool(false)
isStorexTablet() bool(false)
isVodafoneTablet() bool(false)
isEssentielBTablet() bool(false)
isRossMoorTablet() bool(false)
isiMobileTablet() bool(false)
isTolinoTablet() bool(false)
isAudioSonicTablet() bool(false)
isAMPETablet() bool(false)
isSkkTablet() bool(false)
isTecnoTablet() bool(false)
isJXDTablet() bool(false)
isiJoyTablet() bool(false)
isFX2Tablet() bool(false)
isXoroTablet() bool(false)
isViewsonicTablet() bool(false)
isVerizonTablet() bool(false)
isOdysTablet() bool(false)
isCaptivaTablet() bool(false)
isIconbitTablet() bool(false)
isTeclastTablet() bool(false)
isOndaTablet() bool(false)
isJaytechTablet() bool(false)
isBlaupunktTablet() bool(false)
isDigmaTablet() bool(false)
isEvolioTablet() bool(false)
isLavaTablet() bool(false)
isAocTablet() bool(false)
isMpmanTablet() bool(false)
isCelkonTablet() bool(false)
isWolderTablet() bool(false)
isMediacomTablet() bool(false)
isMiTablet() bool(false)
isNibiruTablet() bool(false)
isNexoTablet() bool(false)
isLeaderTablet() bool(false)
isUbislateTablet() bool(false)
isPocketBookTablet() bool(false)
isKocasoTablet() bool(false)
isHisenseTablet() bool(false)
isHudl() bool(false)
isTelstraTablet() bool(false)
isGenericTablet() bool(false)
isAndroidOS() bool(false)
isBlackBerryOS() bool(false)
isPalmOS() bool(false)
isSymbianOS() bool(false)
isWindowsMobileOS() bool(false)
isWindowsPhoneOS() bool(false)
isiOS() bool(false)
isMeeGoOS() bool(false)
isMaemoOS() bool(false)
isJavaOS() bool(false)
iswebOS() bool(false)
isbadaOS() bool(false)
isBREWOS() bool(false)
isChrome() bool(false)
isDolfin() bool(false)
isOpera() bool(false)
isSkyfire() bool(false)
isEdge() bool(false)
isIE() bool(false)
isFirefox() bool(false)
isBolt() bool(false)
isTeaShark() bool(false)
isBlazer() bool(false)
isSafari() bool(false)
isWeChat() bool(false)
isUCBrowser() bool(false)
isbaiduboxapp() bool(false)
isbaidubrowser() bool(false)
isDiigoBrowser() bool(false)
isPuffin() bool(false)
isMercury() bool(false)
isObigoBrowser() bool(false)
isNetFront() bool(false)
isGenericBrowser() bool(false)
isPaleMoon() bool(false)
Experimental version() method
version(Webkit) string(6) "537.36"
Other tests
isiphone() bool(false)
isIphone() bool(false)
istablet() bool(false)
isIOS() bool(false)
isWhateverYouWant() bool(false)
Debug
Matching Regex NULL
Matching Array NULL

Accessing Methods With PHP

		
<?php

	// Any mobile device (phones or tablets).
	if ( $detect->isMobile() ) {
		// do something here
	}
	 
	// Any tablet device.
	if( $detect->isTablet() ){
		// do something here
	}
	 
	// Exclude tablets.
	if( $detect->isMobile() && !$detect->isTablet() ){
		// do something here
	}
	 
	// Check for a specific platform with the help of the magic methods:
	if( $detect->isiOS() ){
		// do something here
	}
	 
	if( $detect->isAndroidOS() ){
		// do something here
	}

?>