Next Tutorial

Drupal 7 Tutorial Part 15: Drupal 7 Advanced Taxonomy Concepts

How to add google analytics javascript code to Drupal Site ?

Submitted by anilsagar on Thu, 08/04/2011 - 18:15

Install and Use google analytics module http://drupal.org/project/google_analytics provided by drupal.org community to easily install Google Analytics Javascript Code to your drupal site.

After installing this module you have full flexibilty to enable or disable the Google Analytics JS code in specific pages of your drupal site.

Stay tuned for more drupal tips :-)

3 comments

Isn't it really silly and

Submitted by Anonymous (not verified) on Sun, 01/22/2012 - 07:10.

Isn't it really silly and lame that we need a module to add simple Google analytics javascript code? This only goes to show the weakness of Drupal.

It Depends

Submitted by anilsagar on Sun, 01/22/2012 - 18:02.

Dear User,

It depends on requirement. In Drupal features are available as modules. Modules are optimized and tested by the community.

Google Analytics modules provides below functionality apart from just tracking code to the site.

Single/multi/cross domain tracking
Selectively track/exclude certain users, roles and pages
Monitor what type of links are tracked (downloads, outgoing and mailto)
Monitor what files are downloaded from your pages
Custom variables support with tokens
Custom code snippets
Site Search support
AdSense support
Tracking of Goals
Anonymize visitors IP address
Cache the Google Analytics code on your local server for improved page loading times
Access denied (403) and Page not found (404) tracking
DoNotTrack support (non-cached content only)

Drupal is not weak. Drupal is so powerful and flexible. You can add google analytics code with out a module also. Just insert the script code in page.tpl.php

Hope you will change your view on Drupal.

Cheers,
Anil Sagar

sam

Submitted by medion akku (not verified) on Tue, 08/30/2011 - 13:36.

nice post you shared.

Post new comment

The content of this field is kept private and will not be shown publicly.
CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters shown in the image. Ignore spaces and be careful about upper and lower case.
©2010 AnilSagar. All rights reserved. Drupal theme by Kiwi Themes.