Uploaded image for project: 'Magnolia Google Analytics'
  1. Magnolia Google Analytics
  2. MGNLGA-2

Testing: Link tracking doesn't work as expected

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Blocker Blocker
    • 1.0-RC6
    • None
    • None

      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.

        Acceptance criteria

              cringele Christian Ringele
              cringele Christian Ringele
              Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: