Auto-tag Outbound Links for Google Analytics


/ Published in: jQuery
Save to your folder(s)

This will automatically tag external links and prefix the URL with '/outgoing' for tracking in Google Analytics. The pageTracker is assumed to be added to the page elsewhere in the markup. By default it is applied to all links contained in the BODY tag, excluding those with the class 'noAutoLink.' This snippet is not an original work of mine, but I do not know its author.

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.