{"id":938,"date":"2010-04-18T13:35:41","date_gmt":"2010-04-18T17:35:41","guid":{"rendered":"http:\/\/2d823b65bb.nxcli.io\/?p=938"},"modified":"2010-04-19T00:20:50","modified_gmt":"2010-04-19T04:20:50","slug":"browser-choice-fail","status":"publish","type":"post","link":"https:\/\/www.robweir.com\/blog\/2010\/04\/browser-choice-fail.html","title":{"rendered":"Yet Another Browser Choice Fail"},"content":{"rendered":"<p>A few weeks ago I wrote about Microsoft&#8217;s &#8220;browser choice&#8221; ballot page in Europe, which in its debut used a <a href=\"https:\/\/2d823b65bb.nxcli.io\/blog\/2010\/03\/new-microsoft-shuffle.html\">flawed algorithm<\/a> when attempting to perform a &#8220;random shuffle&#8221; of the browser choices, a feature specifically called for in their agreement with the EU.\u00a0 This bug <a href=\"https:\/\/2d823b65bb.nxcli.io\/blog\/2010\/03\/new-microsoft-shuffle.html\">was fixed<\/a> soon after it was reported.\u00a0 But I recently received an email from a correspondent going by the name &#8220;Skoon&#8221; who reported a more serious bug, but one that is seen only in the Polish-language translation of the ballot choice screen.<\/p>\n<p>You can go directly to this version of the page via this URL <a href=\"http:\/\/www.browserchoice.eu\/BrowserChoice\/browserchoice_pl.htm\">www.browserchoice.eu\/BrowserChoice\/browserchoice_pl.htm<\/a>.\u00a0 Try loading it a few times.\u00a0 Does it look random to you?\u00a0 I tried it in Internet Explorer, Firefox, Chrome and Opera and get the same result each time.\u00a0 The order is unchanging, with Internet Explorer always first, followed always by Firefox, Opera, Chrome and Safari, in that order.\u00a0 There is no shuffling going on at all.<\/p>\n<p>I won&#8217;t bore you with the details of why this is so.\u00a0 Let&#8217;s just say that this is a JavaScript error involving a failure to properly escape embedded quotations in one of the browser descriptions.\u00a0 Because of the error, the script aborts and the randomization routine is never called.<\/p>\n<p>See if you can find the bug.\u00a0 Hint: turn on your JavaScript error checking in your browser (e.g., Tools\\Error Console in Firefox) and the error will pop out immediately:<\/p>\n<p><a href=\"https:\/\/2d823b65bb.nxcli.io\/blog\/wp-content\/uploads\/2010\/04\/browserchoice-pl.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-943 aligncenter\" title=\"browserchoice-pl\" src=\"https:\/\/2d823b65bb.nxcli.io\/blog\/wp-content\/uploads\/2010\/04\/browserchoice-pl.png\" alt=\"\" width=\"681\" height=\"387\" srcset=\"https:\/\/www.robweir.com\/blog\/wp-content\/uploads\/2010\/04\/browserchoice-pl.png 681w, https:\/\/www.robweir.com\/blog\/wp-content\/uploads\/2010\/04\/browserchoice-pl-300x170.png 300w\" sizes=\"auto, (max-width: 681px) 100vw, 681px\" \/><\/a><\/p>\n<p>If you can detect this error in 30 seconds by enabling Internet Explorer&#8217;s own JavaScript error detection facility &#8212; and I believe you can &#8212; then we can assume that anyone could have done this, even Microsoft.\u00a0 The odd thing is that evidently no one at Microsoft bothered to check this page for JavaScript errors, or even check the page to see if it actually worked.\u00a0 We&#8217;re not talking about sophisticated statistical testing here.\u00a0 Any QA on the page, any at all, would have found this error.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A few weeks ago I wrote about Microsoft&#8217;s &#8220;browser choice&#8221; ballot page in Europe, which in its debut used a flawed algorithm when attempting to perform a &#8220;random shuffle&#8221; of the browser choices, a feature specifically called for in their agreement with the EU.\u00a0 This bug was fixed soon after it was reported.\u00a0 But I [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","footnotes":""},"categories":[35],"tags":[],"class_list":{"0":"post-938","1":"post","2":"type-post","3":"status-publish","4":"format-standard","6":"category-microsoft","7":"entry"},"_links":{"self":[{"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/posts\/938","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/comments?post=938"}],"version-history":[{"count":6,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/posts\/938\/revisions"}],"predecessor-version":[{"id":941,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/posts\/938\/revisions\/941"}],"wp:attachment":[{"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/media?parent=938"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/categories?post=938"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.robweir.com\/blog\/wp-json\/wp\/v2\/tags?post=938"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}