[MGNLGA-2] Testing: Link tracking doesn't work as expected Created: 13/Aug/09  Updated: 23/Jul/15  Resolved: 17/Feb/10

Status: Closed
Project: Magnolia Google Analytics
Component/s: None
Affects Version/s: None
Fix Version/s: 1.0-RC6

Type: Bug Priority: Blocker
Reporter: Christian Ringele Assignee: Christian Ringele
Resolution: Fixed Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Picture 2.png    
Template:
Acceptance criteria:
Empty

 Description   

I am testing the GA module on the demo http://demo.magnolia-cms.com/demo instance.
Generally the tracking of the pages themselves work as expected. All the pages and page hits are tracked and show up in the GA.

The JS tracking script the module is using is a JQuery plugin (in module JS 'jquery.gatracker.js'). It is supposed to track all links too: external links, download links and mailto links.
It adds if found, a prefix to the link URL: 'external' or 'downloads' or 'mailtos'.

Setup:

  • First I tried a advanced tracker function call with more defined file extensions (in module init.gatracker.js').
  • Then I tried the original function call. So its the unchanged JS running as provided by JQuery:
    (function($){
    $.gaTracker('${trackerID}');
    })(jQuery);
    This call activates the link tracking with the original options defined in the original JS script 'jquery.gatracker.js'.

Results:

  • External links are never tracked
  • mailto links are never tracked
  • download links are only very seldom tracked:
    Only download links which point to a .jpg provided by the image module/image-zoom generator. See attached file.

I think the problem is located within the js function 'function decorateLink(u){'.
The regex expression within this function does not apply to the links analyzed.



 Comments   
Comment by Christian Ringele [ 17/Feb/10 ]

Is resolved by:

jQuery.noConflict();
(function($){
$(document).ready(function(){
...
}

Generated at Mon Feb 12 05:50:24 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.