This article contains references to our Classic interface that will become obsolete on July 1st. The most up-to-date article can be found on How to install Mopinion with Google Tag Manager?
This article explains how to implement the Mopinion tag in the Google Tag Manager using the Mopinion Deployment template. It is also possible to implement the Mopinion tag with GTM using the classic setup.
Google Tag Manager (GTM) is a free tag management system. Instead of implementing the Mopinion Deployment Code (MDC) directly into your web pages' HTML code, you can install the tag manager script once and control the Mopinion script from within Google.
- GTM account
- GTM container installed on your webpages
Please refer to https://support.google.com/tagmanager/answer/6103696 and https://tagmanager.google.com for installing Google Tag Manager. Once you have GTM set up on your domain, you can implement the Mopinion Deployment Code.
You start by creating a new tag in GTM.
Give your tag a convenient name, so you know it is used to load the Mopinion Deployment Code.
Click on the 'Tag Configuration' panel. This opens the "Choose tag type" menu.
Click on "Discover more tag types in the Community Template Gallery".
In the "Community Template Gallery" search for "Mopinion Deployment".
Select the Mopinion Deployment and click on "Add to workspace".
A message will ask you if you are sure you want to add the template. Click on "Add" to proceed.
The next step is adding the deployment ID of your deployment. Log into your Mopinion account and follow the next steps.
Getting the deployment ID
Navigate to "Data collection > Deployments".
Select the pencil to edit the deployment.
The deployment ID is the string at the end of the URL in the deployment editor.
Copy the string and paste the deployment ID in the designated field in the Google Tag Manager.
Now that the Mopinion Deployment Code is linked to the tag you can set the condition when the tag should be fire by clicking the 'Trigger Configuration' button.
You can then either choose one of your existing triggers or create a new one. We are going to create a new one by clicking on the '+' button.
You are then asked to select the type. There are 3 types that fire based on events that take place during the loading of the page. More information on the diffent types can be found on https://support.google.com/tagmanager/answer/7679319.
We opt for the 'Window Loaded' type. Since we want the Mopinion Deployment Code to be loaded on all pages of the domain we select that the trigger fires on ‘All Window Loaded Events’.
Your tag is now equipped with your unique Mopinion Deployment Code and a trigger to load the tag on every page. Hit 'SAVE’ to proceed to publish your tag.
In the overview of your workspace you see that 2 changes are ready for publication. You can either 'PREVIEW' or 'SUBMIT' the changes directly. If you 'PREVIEW' the changes only you or the people you invite can see the changes in your domain.
On a URL where the tag is loaded in preview mode, you should see a Google Tag Manager pane that showcases that the Mopinion Deployment Code tag has been fired on the event 'Window Loaded'.
Once satisfied with changes, you can 'SUBMIT' them and make them available for all your visitors. Before you 'PUBLISH' the changes you are asked to name the version with the changes. We would advise to give it a clear name and description, so you know this version hold the Mopinion Deployment Code.
Now you can deploy your forms with different triggers by editing the deployment in Mopinion.