Goodbye Google Analytics, StatCounter, and SiteMeter
Published Fri, Aug 1 2008 11:33 PM
Technorati Tags: Annoyances
I've temporarily removed the Google Analytics, StatCounter, and SiteMeter code from my site. I've always been suspicious of needlessly obfuscated code that inserts tags into page markup. I tried doing an analysis of the Google Analytics code once and didn't care for what I saw.
After watching Internet Explorer crash while using it to view my site from two different machines today while Firefox and Opera worked just fine I started wondering what was going on. Well, I found out. Some Javascript code that manipulates the document object model (DOM) causes Internet Explorer 6, 7, and 8 to go haywire if the document isn't fully loaded. I tried using the "defer" attribute on the scripts that cause the problem with no luck. The code used by these three lovely widgets exposes a bug in Internet Explorer's HTML parsing code. The bug is still present in Internet Explorer version 8, but they've done a better job of recovering with the new browser.

About the only code that inserts elements into the DOM on my site now is the Dumb Ox Bloggregator. I've temporarily taken the rest of it down until I can figure out why it causes Internet Explorer to hurl. Any one of these three tools will cause the error you see above in Internet Explorer. What mystifies me is that the Bloggregator uses the same techniques as these other three tools to insert code into the site, and it still works.
This is one of the reasons I stopped using Internet Explorer as my primary browser some time ago. They insist upon saying that their browser is exhibiting the right behavior. I hardly call crashing proper behavior. I much prefer using Firefox for most things anyway. It's CSS compliance is far better than Internet Explorer's for one thing. It's also more stable.
I still keep Internet Explorer around though. Close to 70% of the visitors to my site use it, at least they do according to the statistics I was getting from SiteMeter until I had to remove their code to let Internet Explorer keep running properly. I also need it for some of the work I do in my straight job. At least I'll still get statistics from SiteMeter, but it's going to be a limited set for a while. Oh well.
SiteMeter is working on an upgrade to their service and it's going to handle the tracking code differently. Maybe it will work without injecting HTML into the document. I don't know about Statcounter, but I rarely use their statistics anymore anyway, so that's not going to be much of a loss. Still it's a shame to have to turn off some perfectly good utilities because Microsoft can't seem to fix bugs rather than explain them away.
[Update:David at third world county has something to say about this too. He's not quite as kind to Microsoft (I believe he calls the product Me$$ySoft Internet Exploder) as I am. Walls of the city blames the problem on SiteMeter. Even so, it's really Microsoft's bug!
Get a REAL browser. Use Firefox, Opera, or Safari!]
Trackback URI for this post: http://perrinelson.com/track.aspx?postid=1216
Permalink URI for this post: http://perrinelson.com/2008/8/1/1216.aspx
Subscribe to this entry's
comment feed. (Atom)
David responded with:
 | "Microsoft can't seem to fix bugs rather than explain them away."
That's precisely the behavior that has driven me away from Microsoft products, for the most part. The arrogant "We don't give a damn about the user" attitude really started to chap my gizzard.
I fear the once semi-sorta-almost-halfway-responsive Microsoft has fallen prey to a variation of Jerry Pournelle's Iron Law of Bureaucracy and is now completely in the hands of the type two personality it describes. |
Layla responded with:
 | Well I have always used FF but too keep IE around in the rare instance I need to use it for windows updates. Otherwise it is worthless. Opera is nice too. I am not very fond of Safari but I have it as a backup like Opera. Netscape is good too, but I thought it was going to be dropped - am I wrong on that?
I cannot take out my site meter, bound to it by my contract with Pajamas Media Network. So, I will see how sitemeter resolves this one....sigh............. |
Perri Nelson responded with:
 | Well, actually Sitemeter's not gone on my site. I'm just using the HTML code, but that doesn't display the meter. It still collects statistics, but I lose things like out-clicks and some of the other statistics that I can get with the Javascript version.
Sitemeter is working on a different collection script that's due out soon. The meter itself will be separate from the statistics collection. That will be interesting to see in action. |
Angel responded with:
 | hey there Perri...I use both browswers ..it seems to be fixed and didnt appear to be malicious!..smiles~!:) |
Perri Nelson responded with: Brought back
 | I've brought the statcounter and sitemeter dynamic scripts back into the site. I have not brought the Google analytics code back. I never said that these scripts were malicious. I did say that Internet Explorer has a bug that Microsoft refuses to fix. A browser that fails to work when executing script that manipulates the markup while other browsers succeed is still an inferior product to my mind. |
Perri Nelson responded with: SiteMeter
 | SiteMeter has a blog post up about this issue. They were making some changes to their javascript code, and this is what was causing the problem... but SiteMeter should not have had to "fix" their scripts to accomodate Microsoft's bug. Microsoft should fix the bug. |
Comments to this entry are closed.