Documentation

Core_Browser
in package

Browser

Tags
subpackage

Core

version
7.x
author

Hostmake LLC

copyright

© 2005-2022 ООО "Хостмэйк" (Hostmake LLC), http://www.hostcms.ru

Table of Contents

check()  : mixed
Check if browser is correct
getBrowser()  : string
Get browser name
getBrowserIco()  : string
Get browser ICO
getDevice()  : int
Get device type by User Agent
getOs()  : string
Get OS name

Methods

check()

Check if browser is correct

public static check() : mixed
Tags
deprecated
6.7.0
Return values
mixed

getBrowser()

Get browser name

public static getBrowser(string $userAgent) : string
Parameters
$userAgent : string

User agent

Return values
string

getBrowserIco()

Get browser ICO

public static getBrowserIco(string $browser) : string
Parameters
$browser : string

Browser name

Return values
string

getDevice()

Get device type by User Agent

public static getDevice(string $userAgent) : int
Parameters
$userAgent : string
Return values
int

0 - desktop, 1 - tablet, 2 - phone, 3 - tv, 4 - watch

getOs()

Get OS name

public static getOs(string $userAgent) : string
Parameters
$userAgent : string

User agent

Return values
string

Search results