Support » Plugin: Quantcast Choice » Choice + Google Tag Manager (GTM) Setup & Support

  • Plugin Author Ryan

    (@rbaronqc)


    Choice + Google Tag Manager

    For Choice Plugin:
    1. Add your UTID and enable Choice TCF v2.0.
    2. Enable Choice to automatically push consent signals to the data layer.

    For Google Tag Manager:
    1. In google tag manager you can import this container (unzip and import the GTM-CONTAINER-QC-CHOICE-google-advertising-products.json file into your GTM container )

    This container has all of the necessary variables to listen for consent data being pushed to the data layer (please enable this option from the Choice plugin WordPress admin page) along with ready made Google Advertising Products Triggers and one Demo example tag to show the trigger group added to a tag. This tag is not added to the page unless the user has given Google consent along with Purpose 1 consent.

    You can read more about the different trigger types in the guide here

    Here is an example video where I am importing a similar container (not the same one), I’m adding the video link to illustrate the process of importing a GTM gtm container, so use the video as a guide to import the downloaded container.

    After successfully importing the container with the variables, triggers and an example tag you should have the following new items in your GTM container.

    New Triggers
    QCConsent-Triggers

    New Variables
    QCConsent-Variables

    Example Tag (for Demo only)
    QCConsent-Tags

    2. Add your Google Advertising Products tag to your website using the QC – Trigger Group – All Pages with Google Advertising Products and Purpose 1 Consent. (See the example tag A DEMO – Google Advertise Tag Example (DEMO ONLY – NOT A REAL TAG)

    See Demo Video here:

    This video essentially begins after importing the demo GTM container linked above and is meant

Viewing 9 replies - 1 through 9 (of 9 total)
  • This looks like an adblocker: if no consent, no ad.

    But if there is no consent, we must display a non-personalized ad. Otherwise, it is the operation of an adblocker, right?

    Thanks Ryan for this great tutorial.

    Could you develop point 2 (For Google Tag Manager) on “Adding your Google Advertising Products tag to your website….”?. I don’t know how to get that tag for my website.

    • This reply was modified 1 year, 1 month ago by marlaskas.
    • This reply was modified 1 year, 1 month ago by marlaskas.
    • This reply was modified 1 year, 1 month ago by marlaskas.
    • This reply was modified 1 year, 1 month ago by marlaskas.
    reamca

    (@reamca)

    Hello everyone!

    Good tutorial but I’m in the same situation as @marlaskas.
    @rbaronqc please explain what you mean when you say “Add your Google ad products tag.”or show us a more detailed example.

    Thank you.

    Plugin Author Ryan

    (@rbaronqc)

    @marlaskas @reamca I believe you would just need to replace the contents of the “demo” tag (an probably rename it) provided with a tag like this (your tag may very slightly):

    <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
    <script>
      (adsbygoogle = window.adsbygoogle || []).push({
        google_ad_client: "xxxxxYOUR_IDxxxxx",
        enable_page_level_ads: true
      });
    </script>

    If you replace the contents of the demo tag (DEMO – Google Advertise Tag Example (DEMO ONLY – NOT A REAL TAG)) with the above this code should only be added to the page where you have proper Google consent or where GDPR does not apply.

    • This reply was modified 1 year ago by Ryan.
    wagnard

    (@wagnard)

    @rbaronqc
    Hi,
    Thanks for your help with GTM and Quantcast.
    I do have an issue on my end that I cant seem to be able to solve.
    I tried to test your Demo , and for some reason when I preview with GTM , I can see the Consent window and when I click “Agree” nothing happen after that, on your video we can see under summary that #5 __cmpConsents and #6 Triggers.
    On my end, no #5 and #6
    Any idea why?

    Plugin Author Ryan

    (@rbaronqc)

    @wagnard In WordPress, on the Quantcast Choice plugin settings page, there is an option to “Push IAB & Non-IAB consent data to the Data Layer”. Is that set to Yes?

    wagnard

    (@wagnard)

    @rbaronqc
    Yep that the the problem, I missed that.
    Also is there a guide for other CMS like Drupal, PHPBB,. With drupal I do get the same issue with GTM

    • This reply was modified 1 year ago by wagnard.
    wagnard

    (@wagnard)

    @rbaronqc Finally it is not working on WordPress, Even with the option ticked, when I click “agree” the cookie euconsent-v2 is created and no __CMPConsent is fired. it stay at Window loaded.
    Any idea?

    Edit: Not sure if it’s related but I see this in the devconsole:
    DevTools failed to load SourceMap: Could not load content for https://www.mywebsite.com/wp-content/plugins/quantcast-choice/public/css/style.min.css.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
    DevTools failed to load SourceMap: Could not load content for https://www.mywebsite.com/wp-content/plugins/quantcast-choice/public/js/script.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

    • This reply was modified 1 year ago by wagnard.
    • This reply was modified 1 year ago by wagnard.
    • This reply was modified 1 year ago by wagnard.
    wagnard

    (@wagnard)

    OK was able to fix it, the problem is on your side, I had to add a non-IAB vendor. If there is none, then it wont work.

    Also, I saw that the trigger wont work if “WHICH USERS SHOULD BE ASKED FOR CONSENT?” is set to only users in the UUK and the page is accessed from the US for example.

    The __CMPConsent is fired but not the trigger.
    Note: __CMPConsent appear before the window Loaded. Not sure if it has anything to do…

    It is as if __CMPConsent happen too soon.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Choice + Google Tag Manager (GTM) Setup & Support’ is closed to new replies.