Can't see Form ID in GTM for Embed Forms | Community
Skip to main content
Yifat_Danieli
Level 3
October 24, 2017
Question

Can't see Form ID in GTM for Embed Forms

  • October 24, 2017
  • 1 reply
  • 2625 views

I'm trying to create a Form Submit event in Google Tag Manger. We're embedding our forms on WordPress and I can clearly see thier on inspect element:

However, when I'm looking at the GTM debugger, I see the following in the Data Layer:

This makes it very hard to find a variable for me to lean on when specifying the form ID / Element / Click.

Anybody knows what needs to be done here? Do I need to create a new variable? if so where and how do I send this information using GTM?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

Gerard_Donnell4
Level 9
October 24, 2017

Hi @Yifat Danieli,

We track Marketo form fills by tracking the onClick event for the Submit button on the webpage.  GTM is listening for the onClick of the submit button and then captures the page url.

Thanks,

Gerard

SanfordWhiteman
Level 10
October 24, 2017

Mmm, that's not really right. Using the DOM event, you'll get false positives whenever someone *attempts* to submit the form and fails validation.

You should use the Forms JS API 'onSuccess' listener, which fires when the form has actually been submitted.