Cookie Policy and HubSpot Tracking Code

MichaelSchm
Participant

Cookie Policy and HubSpot Tracking Code

 

Hello, 

I need to add the Cookie Policy popup to the extern websites.

 

Now there is this Page to add some events/functions to the tracking code which usually looks like: 

<!-- Load the HubSpot tracking code -->
<!-- Start of HubSpot Embed Code -->
  <script type="text/javascript" id="hs-script-loader" async defer src="//js.hs-scripts.com/{hubId}.js"></script>
<!-- End of HubSpot Embed Code -->

to end up like:

<!-- Load the HubSpot tracking code --><!-- Start of HubSpot Embed Code -->
<script type="text/javascript" id="hs-script-loader" async defer src="js.hs-scripts.com{hubId}.js"></script>
<!-- End of HubSpot Embed Code -->

<!-- Check consent status & revoke consent -->
<script>
var _hsq = window._hsq = window._hsq || [];
_hsq.push(['addPrivacyConsentListener']);
_hsq.push(['revokeCookieConsent']);
</script>

What do i need to add to the code / _hsq array, to make sure the cookies will be really deleted and the tracking really stops?

 

Thanks for your help and answers

 

0 Upvotes
2 Replies 2
jennysowyrda
Community Manager

Hi @MichaelSchm,

 

What is your end goal? Are you looking to add the HubSpot Cookie tracking banner to an external page? 

 

Or, are you looking to delete something from your external pages? 

 

Can you please share a link to the website you're working on and clarify what steps you've tried so far? 

 

The more screenshots, details and information you can provide, the better the Community can assist!

 

Thank you,
Jenny

0 Upvotes
mhulse
Participant

Just a quick not, but isn't your syntax wrong? Should you change hsq to hsp?

0 Upvotes