<?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: Hubspot Landing Page Using Raw HTML integrated with Salesforce in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/Hubspot-Landing-Page-Using-Raw-HTML-integrated-with-Salesforce/m-p/791399#M63826</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/565407"&gt;@RLinder4&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;let's start with a quick refresher of HubSpot forms.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Drag&amp;amp;drop forms are build from properties which are set up in the Hub settings (gear icon top right corner)&lt;/LI&gt;
&lt;LI&gt;You can drag&amp;amp;drop them into a form in the form builder(marketing -&amp;gt; lead gen -&amp;gt; forms)&lt;/LI&gt;
&lt;LI&gt;Starting from Marketing Pro you can set up conditional logic to each field like "show this field if a previous field has value X or is not empty"&lt;/LI&gt;
&lt;LI&gt;HubSpot currently don't support multi-step forms(a real bummer) - but there are ready to use code-solutions for custom modules which can be set up for marketers by developers&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to dive more into drag&amp;amp;drop and away from hardcoded HTML templates my personal approach would be a custom module which let's you select drag&amp;amp;drop forms and keep the salesforce sync&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 1:&lt;/STRONG&gt; Create a new module - if you're not that familiar with &lt;A href="https://developers.hubspot.com/docs/cms/guides/getting-started-with-local-development" target="_blank" rel="noopener"&gt;CLI&lt;/A&gt; you can do it via the design-tools by right-clicking the folder the module should be located in and selecting "new file", selecting "module", give it a name, where it should work/be selectable (pages, blogs, email, quotes)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 2: &lt;/STRONG&gt;Grab any existing embed code or create a new drag&amp;amp;drop form. It doesn't have to be a real form since you'll make the embed code flexible in a bit. Paste it into the module.html(HTML+Hubl) area.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It should look like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "acad5b30-9309-47c8-9b7c-30f413c787ae"
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 3:&lt;/STRONG&gt; Add a form field at the right sidebar to the module and put it into the embed code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}"
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Congratulations &lt;span class="lia-unicode-emoji" title=":party_popper:"&gt;🎉&lt;/span&gt; you've made the embed code flexible! A page-creator/marketer can now select any form from the existing ones&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 4:&amp;nbsp;&lt;/STRONG&gt;The code above is great and works but now you need to dive into the customization. For this check out the&amp;nbsp;&lt;A href="https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options" target="_blank" rel="noopener"&gt;How to customize the form embed code&lt;/A&gt; documentation.&lt;/P&gt;
&lt;P&gt;For instance - if you want (and need) to send the form data to Salesforce after a submit you can change the embed code like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
}
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You don't want to use the default HubSpot formstyling? Disable it by putting " css:'' " into the code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
css: ''
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You'd like to add a specific class to it? Add it like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
css: '',
cssClass: 'SOME-CLASS'
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You'd like to have it more flexible or provide more options to the page-creator/marketer? Add fields at the right sidebar like boolean, choice, text(rich-text not recommended) etc. to the module and enrich the embed code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
{% if module.dont_use_default_styling %} {# this is a boolean #}
css: '',
{% endif %}
cssClass: '{{ module.custom_class }}' {# this is a text field #}
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can also get quite creative with &lt;A href="https://developers.hubspot.com/docs/cms/hubl/for-loops" target="_blank" rel="noopener"&gt;repeaters/for-loops&lt;/A&gt; if you want/need to.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;hope that helps&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>Tue, 09 May 2023 06:29:52 GMT</pubDate>
    <dc:creator>Anton</dc:creator>
    <dc:date>2023-05-09T06:29:52Z</dc:date>
    <item>
      <title>Hubspot Landing Page Using Raw HTML integrated with Salesforce</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Hubspot-Landing-Page-Using-Raw-HTML-integrated-with-Salesforce/m-p/791292#M63821</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;We have a hubspot landing page that is provided to customers via link. It is a questionnaire to collect information form the customer. The customer completes this form clicks submit and I believe via a salesforce site it is then mapping and creating a record with the data from the page to a custom object in Salesforce related to a specific opportunity.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Currently this whole page is written using the Raw HTML option. I need to understand my options for creating more of a drag and drop form to be used for easier support from the team as we are not developers. So, we have text fields, picklist fields, etc on the current page. There is also criteria on when to show and not show additional questions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any direction would be great. Or if this can be handed to the right team. I have not used Hubspot in quite some time.&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;Rachel&lt;/P&gt;</description>
      <pubDate>Mon, 08 May 2023 20:15:14 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Hubspot-Landing-Page-Using-Raw-HTML-integrated-with-Salesforce/m-p/791292#M63821</guid>
      <dc:creator>RLinder4</dc:creator>
      <dc:date>2023-05-08T20:15:14Z</dc:date>
    </item>
    <item>
      <title>Re: Hubspot Landing Page Using Raw HTML integrated with Salesforce</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Hubspot-Landing-Page-Using-Raw-HTML-integrated-with-Salesforce/m-p/791399#M63826</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/565407"&gt;@RLinder4&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;let's start with a quick refresher of HubSpot forms.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Drag&amp;amp;drop forms are build from properties which are set up in the Hub settings (gear icon top right corner)&lt;/LI&gt;
&lt;LI&gt;You can drag&amp;amp;drop them into a form in the form builder(marketing -&amp;gt; lead gen -&amp;gt; forms)&lt;/LI&gt;
&lt;LI&gt;Starting from Marketing Pro you can set up conditional logic to each field like "show this field if a previous field has value X or is not empty"&lt;/LI&gt;
&lt;LI&gt;HubSpot currently don't support multi-step forms(a real bummer) - but there are ready to use code-solutions for custom modules which can be set up for marketers by developers&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to dive more into drag&amp;amp;drop and away from hardcoded HTML templates my personal approach would be a custom module which let's you select drag&amp;amp;drop forms and keep the salesforce sync&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 1:&lt;/STRONG&gt; Create a new module - if you're not that familiar with &lt;A href="https://developers.hubspot.com/docs/cms/guides/getting-started-with-local-development" target="_blank" rel="noopener"&gt;CLI&lt;/A&gt; you can do it via the design-tools by right-clicking the folder the module should be located in and selecting "new file", selecting "module", give it a name, where it should work/be selectable (pages, blogs, email, quotes)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 2: &lt;/STRONG&gt;Grab any existing embed code or create a new drag&amp;amp;drop form. It doesn't have to be a real form since you'll make the embed code flexible in a bit. Paste it into the module.html(HTML+Hubl) area.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It should look like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "acad5b30-9309-47c8-9b7c-30f413c787ae"
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 3:&lt;/STRONG&gt; Add a form field at the right sidebar to the module and put it into the embed code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}"
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Congratulations &lt;span class="lia-unicode-emoji" title=":party_popper:"&gt;🎉&lt;/span&gt; you've made the embed code flexible! A page-creator/marketer can now select any form from the existing ones&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 4:&amp;nbsp;&lt;/STRONG&gt;The code above is great and works but now you need to dive into the customization. For this check out the&amp;nbsp;&lt;A href="https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options" target="_blank" rel="noopener"&gt;How to customize the form embed code&lt;/A&gt; documentation.&lt;/P&gt;
&lt;P&gt;For instance - if you want (and need) to send the form data to Salesforce after a submit you can change the embed code like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
}
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You don't want to use the default HubSpot formstyling? Disable it by putting " css:'' " into the code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
css: ''
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You'd like to add a specific class to it? Add it like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
css: '',
cssClass: 'SOME-CLASS'
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You'd like to have it more flexible or provide more options to the page-creator/marketer? Add fields at the right sidebar like boolean, choice, text(rich-text not recommended) etc. to the module and enrich the embed code like this&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/embed/v2.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;
  hbspt.forms.create({
    region: "na1",
    portalId: "YOUR-PORTAL-ID",
    formId: "{{ module.form.form_id }}",
onFormSubmit:{
{# Some JavaScript with your Salesforce API call #}
},
{% if module.dont_use_default_styling %} {# this is a boolean #}
css: '',
{% endif %}
cssClass: '{{ module.custom_class }}' {# this is a text field #}
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can also get quite creative with &lt;A href="https://developers.hubspot.com/docs/cms/hubl/for-loops" target="_blank" rel="noopener"&gt;repeaters/for-loops&lt;/A&gt; if you want/need to.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;hope that helps&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>Tue, 09 May 2023 06:29:52 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Hubspot-Landing-Page-Using-Raw-HTML-integrated-with-Salesforce/m-p/791399#M63826</guid>
      <dc:creator>Anton</dc:creator>
      <dc:date>2023-05-09T06:29:52Z</dc:date>
    </item>
  </channel>
</rss>

