Created
May 6, 2013 02:28
-
-
Save theaccordance/5523061 to your computer and use it in GitHub Desktop.
jQuery method which runs the Google Analytics Function recordOutboundLinks for links that open a new window.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(window).load(function () { | |
| $('a[target=_blank]').each(function(){ | |
| $(this).attr('onClick', "recordOutboundLink(this, 'Outbound Links', '"+$(this).attr('data-name')+"');return true;"); | |
| }); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment