How do you get the Browser information?
Answers were Sorted based on User's Feedback
Answer / jahanvi
get_browser() attempts to determine the capabilities of the
user's browser. This is done by looking up the browser's
information in the browscap.ini file.
echo $_SERVER['HTTP_USER_AGENT'] . "<hr />\n";
$browser = get_browser();
foreach ($browser as $name => $value) {
echo "<b>$name</b> $value <br />\n";
}
| Is This Answer Correct ? | 8 Yes | 3 No |
Answer / 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 |
What is session in c#?
Is php fully object oriented?
I need to know about the courses which are useful in corporate companies.. especially php/mySQL, Java/j2ee, .NET.. also tell if any other courses are valuable
Create a PHP web script with the following attributes: on start, three HTML form elements are shown: an string input field, a checkbox field, a dropdown/pull down list with 5 elements and a submit button. On submission, the form should be redisplayed (while remaining all options/inputs as the user has selected/entered them). Additionally, the selections/inputs of the user should be displayed in text. Please solve this without the use of any external libraries.
What is the use of friend function?
How i can integrate merchant payment get way in zen cart? in php? plz help me
1 Answers BA Continnum Solutions,
What is inheritance in php? How many types of inheritance supports php?
Tell me how can I display text with a php script?
what is php?
What are major variables in research?
Which database is best for php?
Explain Magento's autoload functionality and how to instantiate classes? What is the process you take when theming a store? Talk about Magento collections and how you use them?