homepage Welcome to WebmasterWorld Guest from 54.227.171.163
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Pubcon Platinum Sponsor 2014
Home / Forums Index / WebmasterWorld / Website Analytics - Tracking and Logging
Forum Library, Charter, Moderators: Receptional & mademetop

Website Analytics - Tracking and Logging Forum

    
Call Google Analytics from an external JS file?
Zandaline

5+ Year Member



 
Msg#: 3497374 posted 4:11 am on Nov 6, 2007 (gmt 0)

Iíve got to deploy Google Analytics across several different websites that have 50+ pages each but each site uses the same proprietary CMS that does not have a common header, footer, or any sort of snippet that I can access. So I have to access each page via this pain-in-the-rear CMS and add the code. Iím concerned that if I ever want to change the GA code with one of the many hacks out there Iíd have to go to every single page and modify it.

Is it possible to put the GA code in an external file? I would host this external file on server A and it would be called by the website which lives on server B.

Thank you.

Z

 

cuiyj

10+ Year Member



 
Msg#: 3497374 posted 6:00 am on Nov 17, 2007 (gmt 0)

Certainly, Google Analytics can be called from an external js file.

I saved [google-analytics.com...] into my website and hacked the code, everything works fine.

GA gather all data as parameters of [google-analytics.com...] GA do not care where the js file is.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / WebmasterWorld / Website Analytics - Tracking and Logging
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved