Browser Detection Flags



The following browser detection properties are available to all scripts:

pui.is_ie; // Microsoft Internet Explorer pui.ie_mode; // Defined only if (is_ie == true) pui.ie_version; // Defined only if (is_ie == true) pui.is_android; // Indicates an Android device, not necessarily Android browser. pui.is_chrome; // Google Chrome pui.is_firefox; // Mozilla FireFox pui.is_opera; // Opera pui.is_safari; // Apple Safari pui.is_edge; // Microsoft Edge based on Chromium only, (e.g. "Version 81" or later.) pui.is_touch; // Is a touch device such as a mobile phone or tablet pui.is_mouse_capable; // The computer or device has a mouse attached



The pui.is_XX flags are Boolean type, and will always be defined. They will be set to true or false, as appropriate. The values pui.ie_version and pui.ie_mode are Number type values which are defined only when pui.is_ie is true. pui.ie_version gives the actual version number of Internet Explorer, and pui.ie_mode gives the Internet Explorer rendering mode. In most situations requiring browser detection, pui.ie_mode is the relevant value.

For example:

if (pui.is_ie && pui.ie_mode < 9) { // Do something different for IE8 and below. }

See here for a discussion on browser detection.

Note: Support for IE8 and IE9 have been dropped in Profound UI Version 6 Fix Pack 1.0.