RE: [PHP] netscape user agent name...
| From: | Jon Haworth | Date: | Wed, 16 Oct 2002 11:01:23 +0000 |
| Subject: | RE: [PHP] netscape user agent name... | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-120160@lists.php.net to get a copy of this message | ||
Hi,
> my question is does Netscape 4.x send "Netscape 4.x"
> or "mozilla something"?
It sends "Mozilla/4.7 [en] (WinNT; I)" (varies with version, language and
OS, obviously).
I use this to sniff Netscape 4:
if (strstr($_SERVER["HTTP_USER_AGENT"], "Mozilla/4.") &&
!strstr($_SERVER["HTTP_USER_AGENT"], "MSIE")) {
echo "<p>You're using netscape 4.</p>";
}
Seems to work OK.
Cheers
Jon