<?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: Google Tag Manager - Push Form Data to dataLayer in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/545831#M49652</link>
    <description>&lt;P&gt;How did you add it? Because i tried too like&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/101258"&gt;@Teun&lt;/a&gt; say but Listener don't appear when i submit a form.&amp;nbsp; If i try without email data, it works but adding that additional code breaks the HTML for me.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 22 Dec 2021 07:32:11 GMT</pubDate>
    <dc:creator>ELobato2</dc:creator>
    <dc:date>2021-12-22T07:32:11Z</dc:date>
    <item>
      <title>Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526052#M48692</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to push a form's email value into the dataLayer once a form has been submitted; I've called the variable "hs-form-email" in the code below.&amp;nbsp; I've been trying lots of different ways, and if I literally just use 'event.data', I can see the names and values in the variable, but I can't find a way to only extract the email value - could someone help?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;script type="text/javascript"&amp;gt;
  window.addEventListener("message", function(event) {
    if(event.data.type === 'hsFormCallback' &amp;amp;&amp;amp; event.data.eventName === 'onFormSubmitted') {
      window.dataLayer.push({
        'event': 'hubspot-form-success',
        'hs-form-guid': event.data.id,
        'hs-form-email' : event.data.email.value
      });
    }
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 14 Nov 2021 20:59:16 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526052#M48692</guid>
      <dc:creator>EMartin51</dc:creator>
      <dc:date>2021-11-14T20:59:16Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526213#M48700</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/280770"&gt;@EMartin51&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There is probably a better way to retrieve the value from the data object, but this should work:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;script type="text/javascript"&amp;gt;
  window.addEventListener("message", function(event) {
    if(event.data.type === 'hsFormCallback' &amp;amp;&amp;amp; event.data.eventName === 'onFormSubmitted') {
      window.dataLayer.push({
        'event': 'hubspot-form-success',
        'hs-form-guid': event.data.id,
        'hs-form-email' : $('input[name="email"]').val()
      });
    }
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;Not sure why, but I've only been able to manipulate and retrieve form data with jQuery, but I love to see a Vanilla JS solution that actually works.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 07:29:40 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526213#M48700</guid>
      <dc:creator>Teun</dc:creator>
      <dc:date>2021-11-15T07:29:40Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526301#M48714</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/101258"&gt;@Teun&lt;/a&gt;&amp;nbsp;- perfect, this works like a charm, thank you very much!&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 11:16:57 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/526301#M48714</guid>
      <dc:creator>EMartin51</dc:creator>
      <dc:date>2021-11-15T11:16:57Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/531106#M48974</link>
      <description>&lt;P&gt;This code was very helpful for what I want to do in GTM. Thank you!&lt;/P&gt;</description>
      <pubDate>Tue, 23 Nov 2021 21:59:23 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/531106#M48974</guid>
      <dc:creator>ondukwe</dc:creator>
      <dc:date>2021-11-23T21:59:23Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/545831#M49652</link>
      <description>&lt;P&gt;How did you add it? Because i tried too like&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/101258"&gt;@Teun&lt;/a&gt; say but Listener don't appear when i submit a form.&amp;nbsp; If i try without email data, it works but adding that additional code breaks the HTML for me.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Dec 2021 07:32:11 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/545831#M49652</guid>
      <dc:creator>ELobato2</dc:creator>
      <dc:date>2021-12-22T07:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/546679#M49685</link>
      <description>&lt;P&gt;Hi Teun, would yo help me how to add this? I got some problem because when i add that code that you posted here. No more hubspot-success-form fires.&amp;nbsp; Its an Custom HTML Tag.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Dec 2021 01:16:19 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/546679#M49685</guid>
      <dc:creator>ELobato2</dc:creator>
      <dc:date>2021-12-24T01:16:19Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/709500#M58095</link>
      <description>&lt;P&gt;Can you please help provide an example of this but for the hubspot meetings form submission?&lt;/P&gt;</description>
      <pubDate>Mon, 24 Oct 2022 16:45:10 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/709500#M58095</guid>
      <dc:creator>ANeita</dc:creator>
      <dc:date>2022-10-24T16:45:10Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/745915#M60662</link>
      <description>&lt;P&gt;You can also dynamically access email input from the data layer with this step by step process.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Key to this process is, that you are not reliant on values being extracted from the DOM and you do not need to know at with position the email field is located since the code retrieves it dynamically.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. HTML Tag that triggers on all pages&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;&amp;lt;script type="text/javascript"&amp;gt;
  window.addEventListener("message", function(event) {
    if(event.data.type === 'hsFormCallback' &amp;amp;&amp;amp; event.data.eventName === 'onFormSubmit') {
      window.dataLayer.push({
        'event': 'hubspot-form-success',
        'hs-data': event.data,
        'hs-id': event.data.id
      });
    }
  });
&amp;lt;/script&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Set up data layer variable called &lt;STRONG&gt;HubSpot Data&lt;/STRONG&gt; where the name of the data layer variable is exactly&amp;nbsp;&lt;STRONG&gt;hs-data&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bildschirmfoto 2023-01-24 um 11.49.24.png" style="width: 999px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/83744iC9E40DCD740F7900/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bildschirmfoto 2023-01-24 um 11.49.24.png" alt="Bildschirmfoto 2023-01-24 um 11.49.24.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3. Set up custom javascript variable – I call it&amp;nbsp;&lt;STRONG&gt;HubSpot Mail (Forms)&lt;/STRONG&gt; – with the following code:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;function() {
  var email;
  for (var i = 0; i &amp;lt; {{HubSpot Data}}.data.length; i++) {
    if({{HubSpot Data}}.data[i].name === 'email') {
      email = {{HubSpot Data}}.data[i].value;
    }
  }
  return email;
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;4. Use the variable&amp;nbsp;&lt;STRONG&gt;HubSpot Mail (Forms)&lt;/STRONG&gt; at your disposal, for example for enhanced conversions in Google Ads.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;5. Set up data layer variable called &lt;STRONG&gt;HubSpot ID&lt;/STRONG&gt; where the name of the data layer variable is exactly&amp;nbsp;&lt;STRONG&gt;hs-id&lt;/STRONG&gt;. You can now also use the ID of the form to send it to Google Analytics 4 as a custom parameter to identify the forms later on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bildschirmfoto 2023-01-24 um 11.49.51.png" style="width: 999px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/83745i3B208CDD7C648DE6/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bildschirmfoto 2023-01-24 um 11.49.51.png" alt="Bildschirmfoto 2023-01-24 um 11.49.51.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you need any clarification about the setup, please reach out anytime!&lt;/P&gt;</description>
      <pubDate>Tue, 24 Jan 2023 10:51:26 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/745915#M60662</guid>
      <dc:creator>NiklasBuschner</dc:creator>
      <dc:date>2023-01-24T10:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/750363#M61034</link>
      <description>&lt;P&gt;This is exactly what I needed. I am getting errors when trying to preview GTM.&amp;nbsp; How did you link these variables to Google Ads?&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 23:54:47 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/750363#M61034</guid>
      <dc:creator>mateostabio</dc:creator>
      <dc:date>2023-02-01T23:54:47Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/750612#M61051</link>
      <description>&lt;P&gt;You create a new variable from the &lt;STRONG&gt;User-provided&lt;/STRONG&gt; Data type and select your&amp;nbsp;&lt;STRONG&gt;HubSpot Mail (Forms)&lt;/STRONG&gt; variable for email and optionally a phone variable for phone.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bildschirmfoto 2023-02-02 um 13.26.53.png" style="width: 999px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/84512i2E2022C8EC18B14F/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bildschirmfoto 2023-02-02 um 13.26.53.png" alt="Bildschirmfoto 2023-02-02 um 13.26.53.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then you add this variable to your Google Ads conversion tag from the option &lt;STRONG&gt;"Include user-provided data from your website"&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bildschirmfoto 2023-02-02 um 13.30.28.png" style="width: 999px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/84513i1A8F5C2DC9F6C141/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bildschirmfoto 2023-02-02 um 13.30.28.png" alt="Bildschirmfoto 2023-02-02 um 13.30.28.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Finally, you just have to &lt;A href="https://support.google.com/google-ads/answer/12785317?hl=en&amp;amp;visit_id=638109368656321507-1507535723&amp;amp;rd=1" target="_blank" rel="noopener"&gt;activate enhanced conversion in the Google Ads conversion configuration&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this helps.&lt;/P&gt;</description>
      <pubDate>Thu, 02 Feb 2023 12:34:12 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/750612#M61051</guid>
      <dc:creator>NiklasBuschner</dc:creator>
      <dc:date>2023-02-02T12:34:12Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/759279#M61596</link>
      <description>&lt;P&gt;Hey &lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/509186"&gt;@NiklasBuschner&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot for sharing this solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Worked perfectly on my end by just doing small tweaks on the CSJ to retrieve other fields from the form.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm glad I came across your post.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Feb 2023 22:42:50 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/759279#M61596</guid>
      <dc:creator>Haccount</dc:creator>
      <dc:date>2023-02-21T22:42:50Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769773#M62300</link>
      <description>&lt;P&gt;This should be the accepted solution in my opinion.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The one Teun mentions isn't working for me.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 15:07:54 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769773#M62300</guid>
      <dc:creator>SebKoppjes</dc:creator>
      <dc:date>2023-03-16T15:07:54Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769775#M62301</link>
      <description>&lt;P&gt;This is indeed a great solution.&lt;/P&gt;
&lt;P&gt;I made a quick video about sending Tagmanager events from HubSpot:&amp;nbsp;&lt;A href="https://youtu.be/s3Ie-tKn0hM" target="_blank"&gt;https://youtu.be/s3Ie-tKn0hM&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Hope this helps someone.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 15:17:20 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769775#M62301</guid>
      <dc:creator>Teun</dc:creator>
      <dc:date>2023-03-16T15:17:20Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769804#M62303</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/111961"&gt;@SebKoppjes&lt;/a&gt;&amp;nbsp;highly appreciated!&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 16:01:12 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769804#M62303</guid>
      <dc:creator>NiklasBuschner</dc:creator>
      <dc:date>2023-03-16T16:01:12Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769892#M62308</link>
      <description>&lt;P&gt;Hey,&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/111961"&gt;@SebKoppjes&lt;/a&gt;&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":waving_hand:"&gt;👋&lt;/span&gt; Please consider clicking the Accept Solution button for&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/509186"&gt;@NiklasBuschner&lt;/a&gt;'s post. I'm sure he'd appreciate it. And it will add it to the top of this post.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you! — Jaycee&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 17:52:30 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/769892#M62308</guid>
      <dc:creator>Jaycee_Lewis</dc:creator>
      <dc:date>2023-03-16T17:52:30Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/770148#M62325</link>
      <description>&lt;P&gt;Isnt it the opening post that can do that only? I dont see the button?&lt;/P&gt;</description>
      <pubDate>Fri, 17 Mar 2023 08:37:43 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/770148#M62325</guid>
      <dc:creator>SebKoppjes</dc:creator>
      <dc:date>2023-03-17T08:37:43Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/787827#M63567</link>
      <description>&lt;P&gt;edit: works for me; thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the solution was referring to the 'onFormSubmit' and not the 'onFormSubmitted' event!&lt;/P&gt;</description>
      <pubDate>Fri, 28 Apr 2023 17:02:38 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/787827#M63567</guid>
      <dc:creator>HSSW</dc:creator>
      <dc:date>2023-04-28T17:02:38Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813236#M65279</link>
      <description>&lt;P&gt;Hi, Thanks for the Solution!&lt;BR /&gt;However I can´t get it to work completely.&lt;BR /&gt;I´m trying to use the variable from the field input as a an Event Parameter in a GA4Event.&lt;BR /&gt;(I´m looking to use a custom input field of "Customer_Segment" to diversify my conversion value based on that, but in this case I´m using your email example so as not to do too many things at once)&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_0-1687972536958.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93865iC359DAB6DFA97001/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_0-1687972536958.png" alt="JNordenskjld_0-1687972536958.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But when I fill out my form and submit in preview mode, I only get "value: undefined":&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SS1.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93862i3E4473B9D035DE2D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SS1.png" alt="SS1.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;In the API CallI can see that the information is there however, but like I said, it doesn´t seem to get picked up by the Event Parameter...&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_1-1687972932094.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93866i28B08D7E25C42B28/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_1-1687972932094.png" alt="JNordenskjld_1-1687972932094.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Do you have any suggestions as to what I should try?&lt;BR /&gt;&lt;BR /&gt;/joel&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Jun 2023 17:24:03 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813236#M65279</guid>
      <dc:creator>JNordenskjöld</dc:creator>
      <dc:date>2023-06-28T17:24:03Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813256#M65280</link>
      <description>&lt;P&gt;Have you created the hs-data Data Layer Variable? This is necessary for the custom javascript variable to work correctly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When in doubt, please show more of your setup so I can assist better.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Jun 2023 17:51:10 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813256#M65280</guid>
      <dc:creator>NiklasBuschner</dc:creator>
      <dc:date>2023-06-28T17:51:10Z</dc:date>
    </item>
    <item>
      <title>Re: Google Tag Manager - Push Form Data to dataLayer</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813663#M65299</link>
      <description>&lt;P&gt;yes, I have the complete setup as your instructions&lt;BR /&gt;Below you can see the complete setup, with my customer Segment input instead of Email. Maybe I´m missing something...?&lt;BR /&gt;&lt;BR /&gt;Thanks!!!&lt;BR /&gt;&lt;BR /&gt;Form submission Listener:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_0-1688045509305.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93919iE624BE443815BFA1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_0-1688045509305.png" alt="JNordenskjld_0-1688045509305.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Data Layer Variable:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_1-1688045569642.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93920i7623E52C97D9AE6A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_1-1688045569642.png" alt="JNordenskjld_1-1688045569642.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Java Script Variable:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_2-1688045663162.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93922i3A900C440495E667/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_2-1688045663162.png" alt="JNordenskjld_2-1688045663162.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;HubSpot ID variable&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_3-1688045730817.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93923iA6417D7B3AF08641/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_3-1688045730817.png" alt="JNordenskjld_3-1688045730817.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;GA4 Event Form Success Tag&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JNordenskjld_4-1688045922650.png" style="width: 400px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/93924i249662D4A5C9AD74/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JNordenskjld_4-1688045922650.png" alt="JNordenskjld_4-1688045922650.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 29 Jun 2023 13:41:27 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Google-Tag-Manager-Push-Form-Data-to-dataLayer/m-p/813663#M65299</guid>
      <dc:creator>JNordenskjöld</dc:creator>
      <dc:date>2023-06-29T13:41:27Z</dc:date>
    </item>
  </channel>
</rss>

