Browser
in package
Browser Detection.
Table of Contents
Constants
- AMAYA = 'Amaya'
- BLACKBERRY = 'BlackBerry'
- CHROME = 'Chrome'
- DRAGON = 'Dragon'
- EDGE = 'Edge'
- FIREBIRD = 'Firebird'
- FIREFOX = 'Firefox'
- GALEON = 'Galeon'
- GOOGLEBOT = 'GoogleBot'
- GSA = 'Google Search Appliance'
- ICAB = 'iCab'
- ICECAT = 'IceCat'
- ICEWEASEL = 'Iceweasel'
- IE = 'Internet Explorer'
- KONQUEROR = 'Konqueror'
- LYNX = 'Lynx'
- MOZILLA = 'Mozilla'
- MSN = 'MSN Browser'
- MSNBOT = 'MSN Bot'
- NAVIGATOR = 'Navigator'
- NETPOSITIVE = 'NetPositive'
- NETSCAPE_NAVIGATOR = 'Netscape Navigator'
- NOKIA = 'Nokia Browser'
- NOKIA_S60 = 'Nokia S60 OSS Browser'
- OMNIWEB = 'OmniWeb'
- OPERA = 'Opera'
- OPERA_MINI = 'Opera Mini'
- PHOENIX = 'Phoenix'
- POCKET_IE = 'Pocket Internet Explorer'
- SAFARI = 'Safari'
- SAMSUNG_BROWSER = 'SamsungBrowser'
- SEAMONKEY = 'SeaMonkey'
- SHIRETOKO = 'Shiretoko'
- SLURP = 'Yahoo! Slurp'
- UNKNOWN = 'unknown'
- VERSION_UNKNOWN = 'unknown'
- VIVALDI = 'Vivaldi'
- W3CVALIDATOR = 'W3C Validator'
- WEBTV = 'WebTV'
- WKHTMLTOPDF = 'wkhtmltopdf'
- YANDEX = 'Yandex'
Properties
- $isChromeFrame : bool
- $isCompatibilityMode : bool
- $isFacebookWebView : bool
- $isRobot : bool
- $name : string
- $userAgent : UserAgent
- $version : string
Methods
- __construct() : mixed
- endCompatibilityMode() : mixed
- Render pages outside of IE's compatibility mode.
- getIsChromeFrame() : bool
- Used to determine if the browser is actually "chromeframe".
- getIsFacebookWebView() : bool
- Used to determine if the browser is actually "facebook".
- getIsRobot() : bool
- Is the browser from a robot (ex Slurp,GoogleBot)?
- getName() : string
- Return the name of the Browser.
- getUserAgent() : UserAgent
- getVersion() : string
- The version of the browser.
- isBrowser() : bool
- Check to see if the specific browser is valid.
- isChromeFrame() : bool
- isCompatibilityMode() : bool
- isFacebookWebView() : bool
- isRobot() : bool
- setIsChromeFrame() : $this
- setIsCompatibilityMode() : $this
- setIsFacebookWebView() : $this
- setIsRobot() : $this
- Set the Browser to be a robot.
- setName() : $this
- Set the name of the OS.
- setUserAgent() : $this
- setVersion() : $this
- Set the version of the browser.
Constants
AMAYA
public
mixed
AMAYA
= 'Amaya'
BLACKBERRY
public
mixed
BLACKBERRY
= 'BlackBerry'
CHROME
public
mixed
CHROME
= 'Chrome'
DRAGON
public
mixed
DRAGON
= 'Dragon'
EDGE
public
mixed
EDGE
= 'Edge'
FIREBIRD
public
mixed
FIREBIRD
= 'Firebird'
FIREFOX
public
mixed
FIREFOX
= 'Firefox'
GALEON
public
mixed
GALEON
= 'Galeon'
GOOGLEBOT
public
mixed
GOOGLEBOT
= 'GoogleBot'
GSA
public
mixed
GSA
= 'Google Search Appliance'
ICAB
public
mixed
ICAB
= 'iCab'
ICECAT
public
mixed
ICECAT
= 'IceCat'
ICEWEASEL
public
mixed
ICEWEASEL
= 'Iceweasel'
IE
public
mixed
IE
= 'Internet Explorer'
KONQUEROR
public
mixed
KONQUEROR
= 'Konqueror'
LYNX
public
mixed
LYNX
= 'Lynx'
MOZILLA
public
mixed
MOZILLA
= 'Mozilla'
MSN
public
mixed
MSN
= 'MSN Browser'
MSNBOT
public
mixed
MSNBOT
= 'MSN Bot'
NAVIGATOR
public
mixed
NAVIGATOR
= 'Navigator'
NETPOSITIVE
public
mixed
NETPOSITIVE
= 'NetPositive'
NETSCAPE_NAVIGATOR
public
mixed
NETSCAPE_NAVIGATOR
= 'Netscape Navigator'
NOKIA
public
mixed
NOKIA
= 'Nokia Browser'
NOKIA_S60
public
mixed
NOKIA_S60
= 'Nokia S60 OSS Browser'
OMNIWEB
public
mixed
OMNIWEB
= 'OmniWeb'
OPERA
public
mixed
OPERA
= 'Opera'
OPERA_MINI
public
mixed
OPERA_MINI
= 'Opera Mini'
PHOENIX
public
mixed
PHOENIX
= 'Phoenix'
POCKET_IE
public
mixed
POCKET_IE
= 'Pocket Internet Explorer'
SAFARI
public
mixed
SAFARI
= 'Safari'
SAMSUNG_BROWSER
public
mixed
SAMSUNG_BROWSER
= 'SamsungBrowser'
SEAMONKEY
public
mixed
SEAMONKEY
= 'SeaMonkey'
SHIRETOKO
public
mixed
SHIRETOKO
= 'Shiretoko'
SLURP
public
mixed
SLURP
= 'Yahoo! Slurp'
UNKNOWN
public
mixed
UNKNOWN
= 'unknown'
VERSION_UNKNOWN
public
mixed
VERSION_UNKNOWN
= 'unknown'
VIVALDI
public
mixed
VIVALDI
= 'Vivaldi'
W3CVALIDATOR
public
mixed
W3CVALIDATOR
= 'W3C Validator'
WEBTV
public
mixed
WEBTV
= 'WebTV'
WKHTMLTOPDF
public
mixed
WKHTMLTOPDF
= 'wkhtmltopdf'
YANDEX
public
mixed
YANDEX
= 'Yandex'
Properties
$isChromeFrame
private
bool
$isChromeFrame
= false
$isCompatibilityMode
private
bool
$isCompatibilityMode
= false
$isFacebookWebView
private
bool
$isFacebookWebView
= false
$isRobot
private
bool
$isRobot
= false
$name
private
string
$name
$userAgent
private
UserAgent
$userAgent
$version
private
string
$version
Methods
__construct()
public
__construct([null|string|UserAgent $userAgent = null ]) : mixed
Parameters
- $userAgent : null|string|UserAgent = null
Tags
endCompatibilityMode()
Render pages outside of IE's compatibility mode.
public
endCompatibilityMode() : mixed
getIsChromeFrame()
Used to determine if the browser is actually "chromeframe".
public
getIsChromeFrame() : bool
Return values
boolgetIsFacebookWebView()
Used to determine if the browser is actually "facebook".
public
getIsFacebookWebView() : bool
Return values
boolgetIsRobot()
Is the browser from a robot (ex Slurp,GoogleBot)?
public
getIsRobot() : bool
Return values
boolgetName()
Return the name of the Browser.
public
getName() : string
Return values
stringgetUserAgent()
public
getUserAgent() : UserAgent
Return values
UserAgentgetVersion()
The version of the browser.
public
getVersion() : string
Return values
stringisBrowser()
Check to see if the specific browser is valid.
public
isBrowser(string $name) : bool
Parameters
- $name : string
Return values
boolisChromeFrame()
public
isChromeFrame() : bool
Return values
boolisCompatibilityMode()
public
isCompatibilityMode() : bool
Return values
boolisFacebookWebView()
public
isFacebookWebView() : bool
Return values
boolisRobot()
public
isRobot() : bool
Return values
boolsetIsChromeFrame()
public
setIsChromeFrame(bool $isChromeFrame) : $this
Parameters
- $isChromeFrame : bool
Return values
$thissetIsCompatibilityMode()
public
setIsCompatibilityMode(mixed $isCompatibilityMode) : $this
Parameters
- $isCompatibilityMode : mixed
Return values
$thissetIsFacebookWebView()
public
setIsFacebookWebView(bool $isFacebookWebView) : $this
Parameters
- $isFacebookWebView : bool
Return values
$thissetIsRobot()
Set the Browser to be a robot.
public
setIsRobot(bool $isRobot) : $this
Parameters
- $isRobot : bool
Return values
$thissetName()
Set the name of the OS.
public
setName(string $name) : $this
Parameters
- $name : string
Return values
$thissetUserAgent()
public
setUserAgent(UserAgent $userAgent) : $this
Parameters
- $userAgent : UserAgent
Return values
$thissetVersion()
Set the version of the browser.
public
setVersion(string $version) : $this
Parameters
- $version : string