3

In the click triggers in Google Tag Manager what is the difference between Click Target vs Click URL?

Source: https://support.google.com/tagmanager/answer/6106961?hl=en

4

Click Target: The target attribute of the clicked element.
Click URL: The HREF attribute of the clicked element, if any.

Per the link provided.

For a click URL it's associated with the HREF attribute of the clicked element or the link's destination. For the click target, its associated with the target attribute of the clicked element or specifies where to open the linked document. Which can be broken down to one of the following:

  • _blank
  • _parent
  • _self
  • _top
  • framename

Details for each attribute can be found here - http://www.w3schools.com/tags/att_a_target.asp

For Instance, let's take the HTML tag with the following syntax:

<a href="http://example.com/going-here" target="_blank">Click Me</a>

For the tag manager the "Click URL" would be http://example.com/going-here and the "Click Target" would be _blank. So let's say you have a condition setup to match all "Click URL" going to http://example.com and also open in a new tab in your browser, then this <a> tag would satisfy your condition.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.