__utm.gif Failed to load resource in Webkit when tracking clicks with Event Listeners
Feb 2, 2011 4:55 PM
Posted in group:
Asynchronous Tracking Code Snippet
Whenever I try to attach an event handler to 'a' tags, in Chrome and Safari (WebKit) I only see tracking fire if the link is opened in a new window/tab. If the target is _main, WebKit returns "failed to load resource" for the __utm.gif request. This issue is specific to the asynchronous Google Analytics tracking code. Shift-click, ctrl-click, and target=_blank all work perfectly, the issue only arises when the target scopes to the active window.
Putting the exact same code in-line via an onclick works fine, but that is cumbersome and completely unrealistic in my applications.