IE7 User Agent String published

The IE7 hackers (the ones at Microsoft hacking on the real IE7, that is, not Dean Edwards :) ) have revealed that IE7’s user agent string will be “Mozilla/4.0 (compatible; MSIE 7.0b; Windows NT 6.0)”.

Those of you who are thinking, so? who cares about user agent strings? should give yourselves a pat on the back. We, the web developers of the world, should not care about them. Using the user agent string to sniff for browsers is very bad, and you should not do it; use feature sniffing instead, where you test for the features that you want to use. Don’t test the user agent string. It’s a bit concerning to me that the IE team are releasing details of the user agent string this early on, because that at least implies that they are expecting people to start testing for it, and that makes them surprisingly out of touch with the way we should be doing things. That’s surprising because they are clueful guys over there (yes, they are, stop the snarky comments), and it would be much more useful to know whether, say, CSS hacks that people are currently using to exclude IE will continue to work.

Still, at least you can now start checking your server access logs to see if people with IE7 are browsing your website.

Sponsors