As stated by Google, on 2010 websites and blogs’ speed will be an important evaluation factor as far as ranking is concerned. Google Analytics is important to know what is happening on your website in order to know who and how many times your website is visited. However, its tracking code slows the page dowloading time a lot. Recently, Google has released a new tracking code (Asynchronous Tracking) meant to solve this issue.
Asynchronous Tracking is a new fast tracking code. Reading from Google Code: “Asynchronous Tracking is an alternative way to track website visitors with Google Analytics. Unlike a traditional installation, asynchronous tracking optimizes how browsers load
ga.js so its impact on user experience is minimized. It also allows you to put your Analytics snippet higher in the page without delaying subsequent content from rendering. The Asynchronous Tracking requires a different Analytics snippet and a different syntax for making tracking API calls.”
What follows is the new code:
var _gaq = _gaq || ;
ga.src = (‘https:’ == document.location.protocol ? ‘https://ssl’ : ‘http://www’) + ‘.google-analytics.com/ga.js’;
(document.getElementsByTagName(‘head’) || document.getElementsByTagName(‘body’)).appendChild(ga);
To start using it, simply remove the old code and place this new code right before </head> in your pages. Of course you have to change the UA-XXXXX-X with your own Google Analytics ID and that’s it!
If you want to know more, if you are looking for detailed instruction, read this guide.
Tags: Google App, news, Web Talk
Related Articles Latest Articles
- How to Change and Use Timezone (Tzutil) in Windows 7
- Enhance the Security of your Login Password in Windows 7
- How to Activate Hardware Acceleration and WebGL in Opera 12
- Fix “This PC Doesn’t Meet System Requirements. If You Want to Install Windows 8, You May Have to Upgrade…” Error
Leave a Comment
Web Talk is best viewed in Firefox.