

A trigger in this case, will be generic, saying fire this tag on all pages.

So, specifically, you can create a tag with Google Analytics, which will get fired when the user accesses any page on your blog/website. More prominently, consider you want to track all the page views of a blog/website. To do so, a trigger will be created, which will say, fire the tag only when the transaction confirmation page is displayed to the user. The tag will indicate whether the transaction was carried out successfully. A real world example will be, consider that a tag is being configured for a successful transaction on an ecommerce page.

Triggers are conditions which can be attached to a tag to function the desired way. More specifically, a trigger can direct a tag to fire when a particular button in a particular form is clicked. For instance, the triggers may decide that a particular tag ‘X’ will be fired when a user performs ‘Y’ action. These are a set of rules to configure a tag to be fired. Triggers actually detect when a tag will be fired. This concludes a quick introduction to a Tag and how it can be created. It can very much be at the top as the one above or it can sit in the footer transmitting the information that is required. The location of a tag can be anywhere in the page source code. (window,document,'script','dataLayer','GTM-M8QLQCZ') Var f = d.getElementsByTagName(s), j = d.createElement(s),
#TAG MANAGER INSTALL#
The following code, as we have seen on the Install Google Tag Manager dialog, is actually a Tag. This not only increases the confusion while managing the tag but also makes it cumbersome to differentiate the data coming from various tags. However, there is an equally important point to note here, one should not overdo the tags on a website.

Having them all in one page is indeed a plus, as the product marketer will get to see multiple metrics associated with the page. Taking a cue from there, with respect to a particular analytical tool, there can be multiple tags associated.
#TAG MANAGER CODE#
Introduction to TagĪs put simply on Google Tag Manager Support website, a tag is a piece of code that sends information to a third party, such as Google Analytics. This concludes the process of adding Google Tag Manager Code to your blog. Replace the & as underlined in the line above with & and click Save theme. J = d.createElement(s),dl = l != 'dataLayer'?' &l = '+l:'' j.async = true j.src = Step 7 − To address this issue, in the Google Tag Manager code under the tag, locate the line with − It will show the following error, and it is normal to see that error. Paste the required code under the tag and then click Save theme. Once you have located the tag, repeat the procedure to copy the code associated with tag from Google Tag Manager.įor ease of locating the tag, typically, tag will begin with. The browser search functionality will come in handy to find the tags. Note − You can use shortcut key Ctrl + F to find the and tag. Step 6 − Similarly, locate the tag in the HTML code. Paste the copied code exactly under the tag opening. Go back to and copy the code in the Install Google Tag Manager dialog box under step 1 above. Step 5 − Locate the tag in the HTML code above. As instructed by GTM, we are required to insert the code at the following locations − Here, we want to install the code Google Tag Manager. An HTML source code for your blog will be visible, as shown in the following figure. Step 4 − Click Edit HTML to edit the HTML code for the blog. Step 3 − From the panel on the left, locate the option: Theme. You will be presented with a screen as shown below with your blog post name in the list. Step 2 − To get the GTM code in the above figure added on the blog, go to and log in with your credentials. Now, here we want to install the Google Tag Manager code on our blog. You will get to see the Install Google Tag Manager dialog box. Step 1 − As shown in the above screenshot, click the container code (GTM-XXXXXXX) at the top right corner besides the label Workspace Changes: 0. While going through the process, we will use the blog (created in the previous chapter) for demonstration of different steps.
#TAG MANAGER HOW TO#
This chapter provides an overview of how to get started with Google Tag Manager, add a tag and analyze it for completeness.
