{"id":20,"date":"2004-11-04T13:54:10","date_gmt":"2004-11-04T13:54:10","guid":{"rendered":"http:\/\/gaisan.com\/wordp\/?p=20"},"modified":"2004-11-04T13:54:10","modified_gmt":"2004-11-04T13:54:10","slug":"browser-identities","status":"publish","type":"post","link":"https:\/\/gaisan.com\/blogs\/?p=20","title":{"rendered":"Browser Identities"},"content":{"rendered":"<p>Browser incompatibilities are definitely the bane of a web developer&#8217;s life. Having spent much of my development life messing around with command lines, I&#8217;m now spending a lot of time looking ath <a href=\"http:\/\/www.w3schools.com\/css\/default.asp\">CSS section of w3schools<\/a> grabbling with CSS positioning &#038; layout issues.<br \/>\n<br \/>\nI decided that I&#8217;d solve some of these browser incompatibilites on the server side rather than with client side javascipt.. MT&#8217;s natty Perl-plugin interface looked the best bet and I whipped up a few quick lines of PERL to pull the <code>HTTP_USER_AGENT<\/code> from the env and parse it. Easy-peasy I thought having read all about browser identities <a href=\"http:\/\/webdeveloper.com\/cgi-perl\/cgi_browser_redirection.html\">here<\/a> <i>(skipped the RFC)<\/i>&#8230; This turned out to be no fun. I learned a lot about writing plugins <b>which are a really great feature<\/b> but when I outputted the browser ID for both IE and Opera I got guess what?<br \/>\n<code>Mozilla\/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.54 [en] <\/code><br \/>Not exactly what I was expecting. A <code>diff<\/code> of the two confirmed that I wasn&#8217;t going nuts. They&#8217;re the same so my plugin is effectively useless for sorting out CSS layout issues between IExploder, Opera and Nutscrape&#8230; 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&#8230; <i>de nouveau au conseil de dessin<\/i> as they say in pidgin french \ud83d\ude1b<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Browser incompatibilities are definitely the bane of a web developer&#8217;s life. Having spent much of my development life messing around with command lines, I&#8217;m now spending a lot of time looking ath CSS section of w3schools grabbling with CSS positioning &#038; layout issues. I decided that I&#8217;d solve some of these browser incompatibilites on the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"_links":{"self":[{"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=\/wp\/v2\/posts\/20"}],"collection":[{"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=20"}],"version-history":[{"count":0,"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=\/wp\/v2\/posts\/20\/revisions"}],"wp:attachment":[{"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=20"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=20"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gaisan.com\/blogs\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=20"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}