How do you get the Browser information?
Answer Posted / ravi rajendra k
If you need a parser for getting OS, browser name and version details, use this pattern in a preg_match_all function.
$pattern = '#(?<browser>' . join('|', $known) .')[/ ]+(?<version>[0-9]+(?:\.[0-9]+)?)#i';
You can see my article www.peacemax.com/11/php/user-agents-php-snippet where i wrote the entire function for getting those details.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is the purpose of basename() function in PHP?
How to insert an new array element in array?
Why php is used with mysql?
Where can I learn php?
What are the two most common ways to start and finish a php block of code?
What is the use of array_search() in php?
What is overloading and overriding in php?
Why do we use cookie?
What are the disadvantages of php?
What is a query give example?
How are cookies created?
What are the types of variables in php?
Why should I learn php?
What are Routines?
What is abstraction php?