RE: [PHP-DB] getting client browser info
| From: | Ford, Mike [LSS] | Date: | Mon, 20 Jan 2003 18:29:19 +0000 |
| Subject: | RE: [PHP-DB] getting client browser info | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-24981@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: Mignon Hunter [mailto:hunter@tic.toshiba.com]
> Sent: 20 January 2003 16:32
>
> Question: Why is it that from an IE client I get the following:
>
> Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)
>
> Why does it say mozilla ???
The clue here is in the next word: "compatible" -- that's Microsoft Internet Explorer
(MSIE) 6.0 claiming it's compatible with Mozilla 4.0 browsers (of course, it's not, but
that's MS for you!).
>
> Here's my code:
>
> Your are currently using: <br>
> <?printf ($_SERVER["HTTP_USER_AGENT"]); ?><br>
>
> You are using : <?printf ($HTTP_USER_AGENT);?> browser
>
>
> btw - Both produce the same. Is it because the apache webserver uses
> Mozilla in a default sort of way ??? hum .
Absolutely nothing to do with Apache -- it's just reporting what the user's browser is
telling it. They're the same because they *are* the same: $HTTP_USER_AGENT is the
register_globals copy of the $_SERVER[] element.
Cheers!
Mike
---------------------------------------------------------------------
Mike Ford, Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS, LS6 3QS, United Kingdom
Email: m.ford@lmu.ac.uk
Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211