get_browser()
get_browser - Tells what the user's browser is capable of
Syntax
mixed get_browser (
string $user_agent,
bool $return_array)
Arguments
- user_agent - The User Agent to be analyzed. By default, the value of HTTP User-Agent header is used; however, you can alter this (i.e., look up another browser\'s info) by passing this parameter. You can bypass this parameter with a NULL value.
- return_array - If set to TRUE, this function will return an array instead of an object.
Description
Attempts to determine the capabilities of the user's browser, by looking up the browser's information in the browscap.inifile.
Version
PHP 4, 5
Return value
The information is returned in an object or an array which will contain various data elements representing, for instance, the browser's major and minor version numbers and ID string; TRUE / FALSE values for features such as frames, JavaScript, and cookies; and so forth.