Welcome to WebmasterWorld Guest from

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

How to get the browser info in PHP


5:29 pm on Jul 12, 2001 (gmt 0)

Preferred Member

10+ Year Member

joined:May 3, 2001
votes: 0

Just a quick question.
I was wondering how I can get the operating sytem with $HTTP_USER_AGENT?
I saw in a different post that to get the borwser you do $HTTP_USER_AGENT (browser).
So would it be $HTTP_USER_AGENT (os) or something similar for the OS?
6:31 pm on July 12, 2001 (gmt 0)

Senior Member

WebmasterWorld Senior Member littleman is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:June 17, 2000
votes: 0

Often, but not always, the OS is identified by the browser's U_A. Here are some examples:
Mozilla/4.7 [en] (WinNT; U)
Mozilla/4.0 (compatible; MSIE 5.5; Windows 98)
Mozilla/4.51 [en]C-CCK-MCD (Win95; I)
Mozilla/4.76 [en] (X11; U; Linux 2.2.17-21mdk i686)

You'll have to extract that info from it.

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members