Hello,

I recently had the need to use the title attribute of a link as a variable for my event tracking. I patched google_analytics_et.js to make this possible. Let me know if this is something you would be interested in integrating into the module. I can do some documentation updates to accommodate the attached code patch. Feedback always welcome.

Cheers, Leah

Comments

markabur’s picture

Status: Active » Needs work

Nice, I was looking to use the link's node title as the event label, and this lets me do it via the !title token.

Please generate the patch from within the module folder, not from the drupal root.

Thanks!

nattyweb’s picture

Exactly what I was looking for - so pleased to find this patch. After removing the module folder location from the patch I was able to successfully apply it to Google Analytics Event Tracking 7.x-1.2.
Thanks very much!

asrob’s picture

Version: 7.x-1.1 » 7.x-1.x-dev
Status: Needs work » Needs review
StatusFileSize
new1.79 KB

Attached a new patch.

Status: Needs review » Needs work

The last submitted patch, 3: create_variable_for_link_title_attribute-2279227-3.patch, failed testing.

asrob’s picture

Status: Needs work » Needs review

The last submitted patch, google_analytics_et_title_variable.patch, failed testing.

frob’s picture

Status: Needs review » Needs work

This has a console.log call in it.

Please remove that line from the patch.