<?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 into pillar pages in CMS Development</title>
    <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166340#M43323</link>
    <description>&lt;P&gt;Yes - if you don't want to provide a form in each page, you can wrap the whole form code in an if-statement like&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% for page in dynamic_page %} {# just an example #}
...
{% if page.form_id_column_name %}
&amp;lt;script charset="utf-8" type="text/javascript" src="//js-eu1.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    portalId: "{{ hub_id }}",
    formId: "{{ page.form_id_column_name }}",
    region: "na1"
  });
&amp;lt;/script&amp;gt;
{% endif %}
...
{% endfor %}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;by doing so it will render the whole form code only if there's a form id&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 18 Jun 2025 16:22:15 GMT</pubDate>
    <dc:creator>Anton</dc:creator>
    <dc:date>2025-06-18T16:22:15Z</dc:date>
    <item>
      <title>How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166093#M43304</link>
      <description>&lt;P&gt;Please help me!!&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 07:42:57 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166093#M43304</guid>
      <dc:creator>MNongrum2</dc:creator>
      <dc:date>2025-06-18T07:42:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166148#M43309</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/953430"&gt;@MNongrum2&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it depends on your setup.&amp;nbsp;&lt;BR /&gt;If your pillar page is build in HubSpot you can&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;use the default form module&lt;/LI&gt;
&lt;LI&gt;use a theme specific form module&lt;/LI&gt;
&lt;LI&gt;create a custom module with a form field (as of now custom modules don't support multi-step forms)&lt;/LI&gt;
&lt;LI&gt;paste the form embed code into the source-code view of a rich-text (not recommended).&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;If you want to embed a HubSpot form on an external page, the best way is to copy/paste the embed code. Depending on your external setup you can either paste it in the source-code view of a rich-text or into a codeblock (if you have something like this)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&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;</description>
      <pubDate>Wed, 18 Jun 2025 10:31:57 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166148#M43309</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2025-06-18T10:31:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166203#M43317</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/953430"&gt;@MNongrum2&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Getting your HubSpot form onto a pillar page is totally doable. The exact method depends on how your pillar page is built:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you're working with HubSpot-hosted pillar pages, the smoothest way is usually to drag in a form module or use your theme’s built-in tools, most themes have an easy way to drop a form right into your layout.&lt;/P&gt;
&lt;P&gt;Or you can create a custom module and add a form field there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you’re working outside of HubSpot, like on a WordPress or Webflow site, you’ll want to grab the embed code from your form’s "Share" tab in HubSpot, then paste it directly into your page's HTML (or into a code block if your builder has one).&lt;/P&gt;
&lt;P&gt;Be cautious when pasting into a rich text editor, as it may not always load scripts properly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you’d like a custom module tailored to your design or layout, I’d be happy to help build that for you as well.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 12:28:59 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166203#M43317</guid>
      <dc:creator>kosalaindrasiri</dc:creator>
      <dc:date>2025-06-18T12:28:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166244#M43318</link>
      <description>&lt;P&gt;Hi, I am using hubspot's built in dynamic pages, so the options you just mentioned would work if my pillar page was a normal page but hubspot's dynamic pages especially the pillar pages, are not available in the page editor. Correct me if I'm wrong&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 14:02:26 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166244#M43318</guid>
      <dc:creator>MNongrum2</dc:creator>
      <dc:date>2025-06-18T14:02:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166255#M43319</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/953430"&gt;@MNongrum2&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;for dynamic pages (HubDB) you can add a new text column and use it for the form-id(you get it from the URL or the embed code).&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;In your dynamic page template, use any embed-code of a form and replace the form-id with the column-name&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% for page in dynamic_page %} {# just an example #}
...
&amp;lt;script charset="utf-8" type="text/javascript" src="//js-eu1.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    portalId: "{{ hub_id }}",
    formId: "{{ page.column_name }}",
    region: "na1"
  });
&amp;lt;/script&amp;gt;
...
{% endfor %}&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;</description>
      <pubDate>Wed, 18 Jun 2025 14:18:50 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166255#M43319</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2025-06-18T14:18:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166304#M43321</link>
      <description>&lt;P&gt;but doing so won't I need to add the form ID in every row in the hubdb??&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 15:35:47 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166304#M43321</guid>
      <dc:creator>MNongrum2</dc:creator>
      <dc:date>2025-06-18T15:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166340#M43323</link>
      <description>&lt;P&gt;Yes - if you don't want to provide a form in each page, you can wrap the whole form code in an if-statement like&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% for page in dynamic_page %} {# just an example #}
...
{% if page.form_id_column_name %}
&amp;lt;script charset="utf-8" type="text/javascript" src="//js-eu1.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    portalId: "{{ hub_id }}",
    formId: "{{ page.form_id_column_name }}",
    region: "na1"
  });
&amp;lt;/script&amp;gt;
{% endif %}
...
{% endfor %}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;by doing so it will render the whole form code only if there's a form id&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 16:22:15 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166340#M43323</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2025-06-18T16:22:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166351#M43324</link>
      <description>&lt;P&gt;I want to the form to be in every pillar page but without the need of adding the form in every row since it might not be user friendly&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 16:42:37 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166351#M43324</guid>
      <dc:creator>MNongrum2</dc:creator>
      <dc:date>2025-06-18T16:42:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166371#M43325</link>
      <description>&lt;P&gt;If it's the same form in the same spot, then add a form module or an embed code to the template directly.&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% module "form"
 path="@hubspot/form"
 form={
  "form_id": "123456-123456-12358-7894", 
  "response_type": "redirect",
  "message": "Thanks for submitting the form.",
  "redirect_id": null,
  "redirect_url": "http://www.google.com"
 }
%}&lt;/LI-CODE&gt;
&lt;P&gt;^ example of the &lt;A href="https://developers.hubspot.com/docs/reference/cms/modules/default-modules#form" target="_blank" rel="noopener"&gt;default form module&lt;/A&gt; usage in a template. Simply modify the data&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to have the same form but want to decide if you'd like to display it or not on a page, add a checkbox or choice column(options: true/false) to your hubdb and use it in an if-statement around the module/embed code&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 17:18:17 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1166371#M43325</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2025-06-18T17:18:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to embed hubspot form into pillar pages</title>
      <link>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1167811#M43350</link>
      <description>&lt;P&gt;&lt;EM&gt;*Note from the moderator:&lt;/EM&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;This content appears to be created with the help of AI tools and might be of low relevance or could contain incorrect information.&lt;/EM&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;We recommend fact-checking the content.&lt;/EM&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;Please use AI responsibly going forward (see &lt;A href="https://community.hubspot.com/t5/Getting-Started-on-the-Community/HubSpot-Community-Guidelines/ba-p/384050#:~:text=revoked%20Community%20membership.-,2.%20Be%20relevant.,-There%E2%80%99s%20a%20lot" target="_blank"&gt;Community Guidelines&lt;/A&gt;).&lt;/EM&gt;&lt;BR /&gt;&lt;BR /&gt;-----------------------&lt;STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;Want to add a form to your pillar page? Here are two easy ways:&lt;BR /&gt;Option 1: Same Form in the Same Spot on Every Page&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;If you're using the same form in the same place across all pillar pages (like in the sidebar or at the bottom), you can just &lt;STRONG data-start="381" data-end="421"&gt;add it directly to the page template&lt;/STRONG&gt;.&lt;/P&gt;
&lt;H4 data-start="424" data-end="442"&gt;How to do it:&lt;/H4&gt;
&lt;UL data-start="443" data-end="803"&gt;
&lt;LI data-start="443" data-end="599"&gt;
&lt;P data-start="445" data-end="599"&gt;If you’re using a &lt;STRONG data-start="463" data-end="481"&gt;coded template&lt;/STRONG&gt;, a developer can drop in a few lines of code with the form’s ID (HubSpot gives you this ID when you create the form).&lt;/P&gt;
&lt;/LI&gt;
&lt;LI data-start="600" data-end="803"&gt;
&lt;P data-start="602" data-end="651"&gt;If you’re using a &lt;STRONG data-start="620" data-end="644"&gt;drag-and-drop editor&lt;/STRONG&gt;, just:&lt;/P&gt;
&lt;OL data-start="654" data-end="803"&gt;
&lt;LI data-start="654" data-end="682"&gt;
&lt;P data-start="657" data-end="682"&gt;Open the form in HubSpot.&lt;/P&gt;
&lt;/LI&gt;
&lt;LI data-start="685" data-end="734"&gt;
&lt;P data-start="688" data-end="734"&gt;Click &lt;STRONG data-start="694" data-end="705"&gt;"Share"&lt;/STRONG&gt; and &lt;STRONG data-start="710" data-end="733"&gt;copy the embed code&lt;/STRONG&gt;.&lt;/P&gt;
&lt;/LI&gt;
&lt;LI data-start="737" data-end="803"&gt;
&lt;P data-start="740" data-end="803"&gt;Add a &lt;STRONG data-start="746" data-end="768"&gt;custom HTML module&lt;/STRONG&gt; to the page and paste the code in.&lt;/P&gt;
&lt;/LI&gt;
&lt;/OL&gt;
&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&lt;STRONG&gt;That’s it — the form will now show up on all pillar pages using that template.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;------------------------------------------------------------------------&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Option 2: Show or Hide the Form Based on a HubDB Setting&lt;/STRONG&gt;&lt;/P&gt;
&lt;P data-start="960" data-end="1099"&gt;If you're using &lt;STRONG data-start="976" data-end="985"&gt;HubDB&lt;/STRONG&gt; to manage pillar pages and want to control whether the form shows up or not &lt;STRONG data-start="1062" data-end="1079"&gt;for each page&lt;/STRONG&gt;, here's what to do:&lt;/P&gt;
&lt;H4 data-start="1101" data-end="1112"&gt;Steps:&lt;/H4&gt;
&lt;OL data-start="1113" data-end="1286"&gt;
&lt;LI data-start="1113" data-end="1193"&gt;
&lt;P data-start="1116" data-end="1193"&gt;In your &lt;STRONG data-start="1124" data-end="1139"&gt;HubDB table&lt;/STRONG&gt;, add a column like “Show Form?” with a Yes/No option.&lt;/P&gt;
&lt;/LI&gt;
&lt;LI data-start="1194" data-end="1286"&gt;
&lt;P data-start="1197" data-end="1286"&gt;In your template, ask HubSpot to &lt;STRONG data-start="1230" data-end="1255"&gt;only display the form&lt;/STRONG&gt; if “Show Form?” is set to Yes.&lt;/P&gt;
&lt;/LI&gt;
&lt;/OL&gt;
&lt;P data-start="1288" data-end="1373"&gt;This is great if you only want the form to show up on &lt;STRONG data-start="1342" data-end="1350"&gt;some&lt;/STRONG&gt; pillar pages, not all.&lt;/P&gt;
&lt;P data-start="1288" data-end="1373"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P data-start="1288" data-end="1373"&gt;&lt;STRONG&gt;Quick Recap&lt;/STRONG&gt;&lt;/P&gt;
&lt;TABLE&gt;
&lt;THEAD&gt;
&lt;TR&gt;
&lt;TH&gt;What You Need&lt;/TH&gt;
&lt;TH&gt;What To Do&lt;/TH&gt;
&lt;/TR&gt;
&lt;/THEAD&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD&gt;Show the same form on all pillar pages&lt;/TD&gt;
&lt;TD&gt;Add form code directly to the template or use the embed code&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;Show the form only on selected pages&lt;/TD&gt;
&lt;TD&gt;
&lt;P&gt;Use HubDB and a Yes/No switch to control it&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;DIV class=""&gt;
&lt;DIV class="" tabindex="-1"&gt;&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;DIV class="" tabindex="-1"&gt;&lt;STRONG&gt;Ankita Gupta&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;HubSpot Advisor&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="grazitti logo-1.png" style="width: 98px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/149033iBBFEBCFAD9E1E981/image-dimensions/98x59?v=v2" width="98" height="59" role="button" title="grazitti logo-1.png" alt="grazitti logo-1.png" /&gt;&lt;/span&gt;&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Fri, 27 Jun 2025 17:42:16 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/How-to-embed-hubspot-form-into-pillar-pages/m-p/1167811#M43350</guid>
      <dc:creator>AGupta58</dc:creator>
      <dc:date>2025-06-27T17:42:16Z</dc:date>
    </item>
  </channel>
</rss>

