How do you track GA events on Marketo form submit? | Community
Skip to main content
March 24, 2016
Question

How do you track GA events on Marketo form submit?

  • March 24, 2016
  • 2 replies
  • 2623 views

Hi Community,

I was wondering if you can help answer the question of being able to edit the HTML of the form embed?

Sample CTA button on a Marketo form:

<button type="submit" class="mktoButton" onclick="ga('send', 'event', 'category', 'action', ‘label');">CTA</button>

In red is what we'd like to add...

How do you you track ga actions on form submit?

Thanks in advance!

Best,

JP

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

2 replies

SanfordWhiteman
Level 10
March 24, 2016

Have you searched the Community?  I've posted and linked to a recipe for this a few times.

March 24, 2016

Hi there, I've done a few searches, but didn't find something that was exactly what I was looking for =\

Can you share a link to the post that you've shared?

What keywords were used?

SanfordWhiteman
Level 10
March 24, 2016

Here's one with the keywords "ga onsubmit": Google Analytics Pageview Form OnSubmit.  Be sure to note my last comment there about hitCallback.

April 12, 2016

You could also use the bullt-in functions in Google Tag Manager to track your form submissions, among many other things.

Ben

SanfordWhiteman
Level 10
April 12, 2016

Not at all. If you do not use the Marketo Forms event model, you're doing it wrong and are guaranteed to lose hits. Please don't advise approaches that ignore the event chain.