History of the browser user-agent string
September 9, 2008 9:31 AM   Subscribe

 
and the article was good
posted by mannequito at 9:38 AM on September 9, 2008 [2 favorites]


The author's got a bit of cause and effect screwed up, and seems to miss the part where MSIE is effectively a successful fork of Mosaic (a consequence of licensing Spyglass, which is a commercialized version of Mosaic), and seems oblivious to whether anybody besides authors of weblog tools ought to give a flying flip about user-agent strings because if you're worried about that level of user agent detection in this day and age to decide what content to deliver to a desktop web browser you're probably doing it wrong.
posted by ardgedee at 9:44 AM on September 9, 2008 [1 favorite]


And.
posted by Dr-Baa at 10:15 AM on September 9, 2008


Good article, but horrible misuse of the "batshitinsane" tag.
posted by Electrius at 10:28 AM on September 9, 2008


They forgot Lynx.
posted by quin at 10:29 AM on September 9, 2008 [1 favorite]


w3m kings
of orient are

posted by cortex at 10:48 AM on September 9, 2008 [5 favorites]


ardgedee: "...seems oblivious to whether anybody besides authors of weblog tools ought to give a flying flip about user-agent strings because if you're worried about that level of user agent detection in this day and age to decide what content to deliver to a desktop web browser you're probably doing it wrong."

Plutor's immutable law of web development: Most web developers are doing it wrong

Corollary 1: The developers who are doing it right suffer as a result.
Corollary 2: The developers who are doing it wrong don't know they're doing it wrong, and don't care.
posted by Plutor at 10:49 AM on September 9, 2008 [15 favorites]


hahahaha awesome.
posted by bonaldi at 10:50 AM on September 9, 2008


In the future, web pages will be self-rendering. Rather then browser sniffing and all kinds of nonsense, they'll send a simple rendering engine along with their page (which can be cached). You're already starting to see something like this with AIR and silver light, the pages get to render themselves. It wouldn't be too hard to build a java script rendering engine that used the canvas.
posted by delmoi at 11:41 AM on September 9, 2008 [5 favorites]


Can someone explain this in English?
posted by backseatpilot at 11:51 AM on September 9, 2008


Can someone explain this in English?

The web was designed by three year olds; everybody wants what the other person has, and as a result nobody plays nice with each other.
posted by jeffamaphone at 11:54 AM on September 9, 2008


It's basically that scene from Spartacus except for without the heartwarmingness and nobility.
posted by cortex at 11:56 AM on September 9, 2008 [5 favorites]


In the future, web pages will be self-rendering.

The Mozilla ActiveX Control.
posted by enn at 12:04 PM on September 9, 2008


backseatpilot: when your browser asks a server for a page, it introduces itself. In the olden days, servers used to send different pages depending on what type of browser was asking. So, to get the good pages, browsers started pretending to be one another. The result is a mishmash of lies and chaos.

The end result is like being asked what type of car you have and replying:
BMW 5-series (petrol, X; 3-litre; injected; USA) VolkswagenGolfTDI (Mercedes-Benz, like Audi) FordFocus/2.0L Camaro/3.0L
posted by bonaldi at 12:17 PM on September 9, 2008 [5 favorites]


(your car in this example is a Ford Focus, btw)
posted by bonaldi at 12:18 PM on September 9, 2008 [4 favorites]


Can someone explain this in English?

When you go to a web page, your browser sends a bit of text, called the user-agent string, to the web server saying what kind of browser it is.

Web servers can then deliver slightly different web pages depending on what browser you've got, since some browsers have more features than others.

This creates a problem whenever someone creates a new browser. Web servers don't recognize it, so they give it the simplest possible web pages without any cool features. (And if the web site developer is really lazy, sometimes it just sends a message saying "please upgrade your browser".)

So, all the new browsers that have come along have tended to send misleading user-agent strings, so they can pretend to be the last successful browser, and get web pages with the cool features.

This has caused a lot of confusion for the people who have to deal with such things.
posted by TheophileEscargot at 12:20 PM on September 9, 2008


Most web developers are doing it wrong

Sigh... count me among their ranks, from time to time. I mean, you can't have it both ways--either you're supposed to do all your page layout in CSS, or you're not, and either every rendering engine behaves the same way when given the same markup using position:relative; directives, or it doesn't. But yes, every '* html body {' I write makes me a worse person.

I'm usually pretty low-intensity about the whole clusterfuck, and reserve the snark about the incompetence of Microsoft's standards-compliance engineering to comments in server-side includes. It actually makes things easier that way, because I can make sure I'm updating every reference by grepping for 'ie hack' in the source tree. One of them is going to slip out, some day, which is why I still check every index page for any errant instances of 'fuck' before promoting to production.
posted by Mayor West at 12:22 PM on September 9, 2008 [5 favorites]


(Also, as someone who usually uses a bog-standard Gecko browser that happens to be built with XULRunner and to use different chrome than Firefox and which has a slightly different user-agent string, I continue to be amazed at and appalled by the number of websites that go into fits because they don't recognize that string.)

(And furthermore, Google News, what is up with serving 403s to requests for feeds with wget's user-agent? I mean they're effing feeds, aren't they? They're supposed to be gotten by a machine. You will only make me use -U in anger. Or Drakma.)
posted by enn at 12:22 PM on September 9, 2008


> But yes, every '* html body {' I write makes me a worse person.

Standards-compliance is a blessing and a curse. Hacks are usually a bad idea, if for other reason than how unpredictably they behave on new version releases.

Microsoft's been providing conditional comments for HTML and Javascript for almost ten years, which means you can compartmentalize all your concessions to Microsoft browsers into a couple discreet documents that proper browsers never have to acknowledge.
posted by ardgedee at 12:39 PM on September 9, 2008 [1 favorite]


Mayor West, the solution is simple, just do what I did: move to Chicago and get a job as a secretary. In your free time, design web pages custom tailored not merely to your browser of choice, but to your personal monitor, and tell everyone else to take a hike.

I really do enjoy coding / designing for the web, but good lord I hated cross-browser compatibility issues.
posted by Squid Voltaire at 12:43 PM on September 9, 2008


Mayor West marks his trail, not with breadcrumbs, but with landmines.

I lurve this post.
posted by cowbellemoo at 1:07 PM on September 9, 2008


This creates a problem whenever someone creates a new browser. Web servers don't recognize it, so they give it the simplest possible web pages without any cool features. (And if the web site developer is really lazy, sometimes it just sends a message saying "please upgrade your browser".)

Or if you're Microsoft you cripple your server software so they break on any non-IE browser. I know it is impossible to create a good mail client in anything but IE, I mean it isn't like someone has been able to accomplish that at all, so they have the normal mode and the "simple mode" so that I have to get out of Firefox and into IE if I ever want to check mail on my Exchange 2007 server. Garrrrrrrrghszhd. Google please release one of your fancy appliances to do my mail.
posted by geoff. at 1:18 PM on September 9, 2008


Also, it occurrs to me--most of the weirdness in user-agent strings comes from the fact that every competing browser assumed that web servers were serving up content based on a partial string match, and the arms race was over the idea that someone else might be getting something extra that your users weren't. Thus, I'm amazed that some brash young upstart on the MSIE team didn't decide to implement the Final Solution:

Mozilla/5.0 (compatible; MSIE 8.0 ,MSIE 7.0, MSIE 6.0, MSIE 5.0, MSIE 4.0, MSIE 3.0; Windows 3.1, Windows 95, Windows NT 5.1, Windows 98, Windows ME, Windows XP, Windows XPSP1, PPC Mac OS X Mach-O; en-US; rv:1.7.2, 1.7, 1.6, 1.5, 1.4, 1.3, 1.2, 1.1, 1.0) Camino/0.8.1 Gecko/20071008 SeaMonkey/1.0 Opera 9.51 FireFox/2.0 Chrome/0.2.149.27 AppleWebKit/525.13 (KHTML, like Gecko), and so on into the night.

It would be cheerfully, hellishly complex and unidentifiable, break any attempts at targeting known violators of standards-compliance, and wreak complete havoc on anyone trying to make any sort of useful reporting system, but by god, it would sure that no feature was left out. Exactly the sort of thing I would have expected from Redmond circa 1999.
posted by Mayor West at 1:33 PM on September 9, 2008 [2 favorites]


And then there's the beautiful fact that some websites have pay-content, and still want to be indexed in google, so they give up their pay-content to every browser with "hello I am a google indexing robot, do you have some delicious content, thank you" in the user agent.

The really fun bit is to see the marketeers being upset when they discover people actually use this little tidbit to avoid paying for their precious...
posted by DreamerFi at 2:06 PM on September 9, 2008 [5 favorites]


Mayor West: Please don't give them ideas. Thanks.
posted by rusty at 2:18 PM on September 9, 2008


what gets me is that at some point in the near future, these strings will actually be one of the things we need to trim for bandwidth. Chrome's is over 100 characters. I visit on the low end 500 webpages in a day, and god knows how many more pages are being requested through AJAX stuff nowadays. Granted, 50k worth of data isn't much, but it's the equivalent of ~25 spam emails worth of bandwidth that I'm producing.
posted by jamuraa at 2:30 PM on September 9, 2008


This is a road paved with pain.
posted by Artw at 9:24 PM on September 9, 2008


Woman (breasts; vagina) 18/f/nyc (college) man/40/basement
posted by tehloki at 11:16 PM on September 9, 2008


tehloki: "Woman (breasts; vagina) 18/f/nyc (college) man/40/basement"

Ah, yes. The World of Warcraft user ident string.
posted by mystyk at 12:31 AM on September 10, 2008 [3 favorites]


« Older Is that a Spicey Sausage in Your Pants?   |   The North Korea of the Privileged Newer »


This thread has been archived and is closed to new comments