Categories
technology

Browser Identities

Browser incompatibilities are definitely the bane of a web developer’s life. Having spent much of my development life messing around with command lines, I’m now spending a lot of time looking ath CSS section of w3schools grabbling with CSS positioning & layout issues.

I decided that I’d solve some of these browser incompatibilites on the server side rather than with client side javascipt.. MT’s natty Perl-plugin interface looked the best bet and I whipped up a few quick lines of PERL to pull the HTTP_USER_AGENT from the env and parse it. Easy-peasy I thought having read all about browser identities here (skipped the RFC)… This turned out to be no fun. I learned a lot about writing plugins which are a really great feature but when I outputted the browser ID for both IE and Opera I got guess what?
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.54 [en]
Not exactly what I was expecting. A diff of the two confirmed that I wasn’t going nuts. They’re the same so my plugin is effectively useless for sorting out CSS layout issues between IExploder, Opera and Nutscrape… So HTTP_USER_AGENT is apparently not the thing to use.. The appName in javascript would be more reliable apparently. SO much for sorting out the problem on the server side. Ah well… de nouveau au conseil de dessin as they say in pidgin french 😛

Leave a Reply

Your email address will not be published. Required fields are marked *