Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixing link tracking and dropdown menus
  • Loading branch information
jmr06005 committed Mar 12, 2018
1 parent d29afdf commit e57d6b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/linktracking.js
Expand Up @@ -9,7 +9,7 @@ function _gaLt(event){
el = el.parentNode;

if(el && el.href){
if(el.href.indexOf(location.host) == -1){ /* external link */
if(el.href.indexOf(location.host) == -1 && el.getAttribute('data-toggle') != 'dropdown'){ /* external link */
_gaq.push(["_trackEvent", "Outgoing Links", el.href, document.location.pathname + document.location.search]);
_gaq.push(["b._trackEvent", "Outgoing Links", el.href, document.location.pathname + document.location.search]);
/* if target not set then delay opening of window by 0.5s to allow tracking */
Expand Down

0 comments on commit e57d6b6

Please sign in to comment.