Mobile Testing Variables

If your website is on BranchCMS Plus or higher then you can enable mobile testing. This will test the user agent of the browser that is loading a page on the website and return some basic information about the device.

This feature is a hold-out of the days when developers used to build mobile-specific templates. Because the current best practice for building websites for small screens is responsive design, and because user agents are not always accurate, this mobile detection feature may be removed in the future.

The following variables are available.

Variable Description
_core.mobile.brandName

The brand name of the mobile device.

_core.mobile.deviceOS

The operating system of the device.

_core.mobile.deviceOSVersion

The device operating system version.

_core.mobile.isAndroid

Whether the device operating system is Android.

_core.mobile.isEnabled

Whether mobile detection is enabled.

_core.mobile.isIOS

Whether the device is an iOS device.

_core.mobile.isMobile

Whether the device is a mobile device.

_core.mobile.isRobot

Whether the device is a robot.

_core.mobile.isTablet

Whether the device is a tablet.

_core.mobile.mobileBrowser

The browser name.

_core.mobile.mobileBrowserVersion

The version of the browser.