deceptikon
Challenge Accepted
3,499 posts since Jan 2012
Reputation Points: 822
Solved Threads: 481
Skill Endorsements: 58
cereal
Veteran Poster
1,195 posts since Aug 2007
Reputation Points: 358
Solved Threads: 231
Skill Endorsements: 22
based on the code you posted, all you need to do is to include the file in your php page and perform a simple switch to get the result you are after. something like this:
yourpage.php
include('get_browser.php');
$browser=getBrowser();
switch ($browser['name'])
{
case 'Google Chrome':
echo "you are using chrome";
break;
case 'Internet Explorer':
echo "you are using ie";
break;
case 'Mozilla Firefox':
echo "you are using firefox";
break;
default:
break;
}
now just a reminder that, if you are looking just to change the CSS based on the browser, this is not the way to do it.
emclondon
Junior Poster in Training
94 posts since Mar 2010
Reputation Points: 48
Solved Threads: 4
Skill Endorsements: 0
It's probably an error in Chrome/front-page.php, check your quotes in that file.
pritaeas
Posting Prodigy
9,534 posts since Jul 2006
Reputation Points: 1,194
Solved Threads: 1,494
Skill Endorsements: 98
The file is probably missing one. Check it!
pritaeas
Posting Prodigy
9,534 posts since Jul 2006
Reputation Points: 1,194
Solved Threads: 1,494
Skill Endorsements: 98