<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to embed Hubspot form to ensure compliance with Cookiebot in CMS Development</title>
    <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155274#M43098</link>
    <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/17186"&gt;@Anton&lt;/a&gt;&amp;nbsp; - since posting, i've been working on an approach like this.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I will post a final soltuion, once one is available - should anyone else have the same issues.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 21 May 2025 14:43:10 GMT</pubDate>
    <dc:creator>CMcCaw</dc:creator>
    <dc:date>2025-05-21T14:43:10Z</dc:date>
    <item>
      <title>How to embed Hubspot form to ensure compliance with Cookiebot</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155185#M43094</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I need to embed a form but ensure compliance with Cookiebot. The form should only show, if the user has selected marketing/statistic cookies etc?&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Any ideas?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 May 2025 12:10:10 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155185#M43094</guid>
      <dc:creator>CMcCaw</dc:creator>
      <dc:date>2025-05-21T12:10:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed Hubspot form to ensure compliance with Cookiebot</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155270#M43096</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/289340"&gt;@CMcCaw&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;to be honest - I've never done something like this, but I could think of a a custom module with an if-statement that will check for the marketing-cookie or trigger the cookie banner...&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% if marketing_cookie %}
{{ module.form }}
...
{% else %} {# &amp;lt;-- if marketing cookie is not set #}
{% require_css %}
&amp;lt;style&amp;gt;
.cookie-overlay{
display:flex;
justify-content:center;
align-items: center;
background-color:#eaeaea;
}
span.cookie-banner-button{
background-color: #f00;
color:#fff;
padding:.75rem 2rem;
font-weight:700;
display:inline-flex;
}
&amp;lt;/style&amp;gt;
{% end_require_css %}
{% require_js %}
&amp;lt;script&amp;gt;
document.querySelectorAll('.cookie-banner-button').forEach(button =&amp;gt; {
    button.addEventListener('click', function() {
        (function(){
            var _hsp = window._hsp = window._hsp || [];
            _hsp.push(['showBanner']);
        })();
    });
});
&amp;lt;/script&amp;gt;
{% end_require_js %}
&amp;lt;div class="cookie-overlay"&amp;gt;
&amp;lt;p&amp;gt;&amp;lt;strong&amp;gt;In order to fill out the form, please enable Marketing cookies&amp;lt;/strong&amp;gt;&amp;lt;/p&amp;gt;
&amp;lt;span class="cookie-banner-button"&amp;gt;Manage Cookies&amp;lt;/span&amp;gt;
&amp;lt;/div&amp;gt;
{% endif %}
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;best,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anton&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 May 2025 14:41:05 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155270#M43096</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2025-05-21T14:41:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed Hubspot form to ensure compliance with Cookiebot</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155274#M43098</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/17186"&gt;@Anton&lt;/a&gt;&amp;nbsp; - since posting, i've been working on an approach like this.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I will post a final soltuion, once one is available - should anyone else have the same issues.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 May 2025 14:43:10 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155274#M43098</guid>
      <dc:creator>CMcCaw</dc:creator>
      <dc:date>2025-05-21T14:43:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed Hubspot form to ensure compliance with Cookiebot</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155299#M43099</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/289340"&gt;@CMcCaw&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Install the &lt;A href="https://knowledge.hubspot.com/integrations/connect-the-cookiebot-integration" target="_blank" rel="noopener"&gt;official Cookiebot app via HubSpot App Marketplace&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;It handles consent flow and auto-sync for HubSpot tools, but for form embeds, you will need conditional script logic.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Refer:&amp;nbsp;&lt;A href="https://support.cookiebot.com/hc/en-us/articles/360015961639-HubSpot-installation" target="_blank" rel="noopener"&gt;https://support.cookiebot.com/hc/en-us/articles/360015961639-HubSpot-installation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Conditional script logic Example :&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;function loadHubspotForm() {
  hbspt.forms.create({ /* your form config */ });
}

if (window.Cookiebot) {
  window.addEventListener('CookiebotOnConsentReady', () =&amp;gt; {
    if (Cookiebot.consent.statistics || Cookiebot.consent.marketing) {
      loadHubspotForm();
    }
  });
} else {
  loadHubspotForm();
}&lt;/LI-CODE&gt;&lt;P&gt;&lt;A href="https://support.cookiebot.com/hc/en-us/articles/6954474867740-Conditionally-loading-code-in-bundles" target="_blank" rel="noopener"&gt;https://support.cookiebot.com/hc/en-us/articles/6954474867740-Conditionally-loading-code-in-bundles&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;PS:&amp;nbsp;Mark HubSpot scripts with &lt;EM&gt;data-cookieconsent="ignore"&lt;/EM&gt; If your embed uses HubSpot’s tracking or scripts blocked by Cookiebot, tag them to bypass auto-blocking.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;script src="https://js.hsforms.net/forms/v2.js" data-cookieconsent="ignore"&amp;gt;&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;This &lt;A href="https://community.hubspot.com/t5/APIs-Integrations/Hubspot-forms-dissapear-from-website-after-consent-denied/m-p/966096" target="_blank" rel="noopener"&gt;prevents forms from vanishing when cookies are denied&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kosala&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 May 2025 15:19:19 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-Hubspot-form-to-ensure-compliance-with-Cookiebot/m-p/1155299#M43099</guid>
      <dc:creator>kosalaindrasiri</dc:creator>
      <dc:date>2025-05-21T15:19:19Z</dc:date>
    </item>
  </channel>
</rss>

