Why is my HTTP_USER_AGENT not always the same?

http, internet-explorer-8, user-agent

Solution

IE 8 will pretend to be IE 7 for backwards compatibility reasons - this is called Compatibility View.

More information: http://msdn.microsoft.com/en-us/library/dd567845%28VS.85%29.aspx

Compatibility View (and therefore an IE 7 user-agent string) is only enabled for specific websites. To view the list, visit

res://iecompat.dll/iecompatdata.xml

Using your IE browser.

Problem

When I print my ENV{'HTTP_USER_AGENT'} at the beginning of each of my perl pages, sometimes it says I'm using IE7 and other times it says I'm using IE8. Any idea why? ``` Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729) Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729) ``` My IE version is actually 8.

Original source