Main Page

Internet Explorer 5.0 and higher

Internet Explorer 5.0 and higher
Microsoft released the next version of IE, 5.0, in 1999. As expected, the user-agent string once again pre-
sented problems. For example, IE 5.0 running on Windows NT 4.0 returned this user-agent string:
Mozilla/4.0 (compatible; MSIE 5.0; Windows NT)
Once again, the IE version was updated, but the Mozilla version was left at 4.0.
This pattern continued as versions 5.5 and 6.0 were released, ultimately leading to a 6.0 user-agent string
similar to this:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT)
Because of this, it’s still necessary to do a separate check for IE.
Mozilla
As part of the development of Netscape 6 (Mozilla), a short document was written up as a specification
for the user-agent string. The new format represented the first departure from Netscape’s original user-
agent string format:
Mozilla/
MozillaVersion
(
Platform
;
Security
;
OS-or-CPU
;
Localization information
?[
;
PrereleaseVersion] *[
;
Optional Other Comments]
) Gecko/
GeckoVersion
[ApplicationProduct/ApplicationProductVersion]
Obviously, a lot of thought went into the user-agent string format. The individual pieces of the user-
agent string are listed in the following table.
String
Required? Description
MozillaVersion
Yes
The version of Mozilla
Platform
Yes
The type of computer system being used. Possible val-
ues: Windows, Macintosh, X11 (for Unix).
Security
Yes
The security of the browser. Possible values: N (for no
security), U (for strong security), I (for weak security).
OS-or-CPU
Yes
Either the operating system the browser is being run
on or the processor type of the computer running the
browser. If the
Platform
is Windows, this is the version
of Windows (such as WinNT, Win95, and so on). If the
Platform
is Macintosh, then this is the CPU (either 68k
or PPC for PowerPC). If the
Platform
is X11, this is the
Unix operating system name as obtained by the Unix
command uname -sm.
Localization information
Yes
The language for the browser. Typically en-US in
America.
230
Chapter 8
11_579088 ch08.qxd 3/28/05 11:38 AM Page 230


JavaScript EditorFree JavaScript Editor     Ajax Editor


©