Hey, I ended up looking at using eregi to pull this information out of the original HTTP_USER_AGENT as this is more accurate than the extra info from browscap.ini. You have to list out all of the browsers & OSs. However, I'm having problems detecting the Amaya browser...
$browser_string = getenv(HTTP_USER_AGENT); ...... $eregi_str = "((\; |\()" . "(MSIE|IE|Netscape|Konqueror|Lynx|Links|Opera)|Gecko|Amaya)" . "[ \\\/\-\.a-z0-9]*(\)|\;|libwww)?"; if( eregi( $eregi_str, $browser_string, $arrstring ) ) { $browser_name = $arrstring[0]; $browser_name = eregi_replace( "(\;|\(|\))", "", $browser_name ); $browser_name = trim( $browser_name ); } else if( $browser->parent ) { $browser_name = $browser->parent; } else { $browser_name = "unknown"; } Amaya displays as "amaya/V4.3.2 libwww/5.3.1" & when printing out $browser_name, it equals "amaya/V4.3.2 libwww/5.3.1" I've thought of using - eregi_replace( "libwww[\/\.a-z0-9]*", "", $browser_name ); - but not sure if I really want to do it this way or not. Any suggestions? Patrick -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php