Tracking Pop Up Form Submission Events with GTM
-
Hello,
I'm currently tracking contact form submissions any time a user clicks 'Submit' on a pop-up form. Once the form is submitted, the URL of the page remains the same (there is no /thank-you page or such like), hence needing to fire the Event based on a click.
Problem is, even if the form is not actually submitted and a user just clicks the Submit button without filling in the fields, the Event will still fire.
I know there is a way to ensure the Event ONLY fires when the form is actually submitted for real, but I don't know how to implement that in GTM.
Any help most appreciated
Cheers,
Gill.
-
Wherever you can edit the thank you message, trigger an event - https://developers.google.com/analytics/devguides/collection/analyticsjs/events
-
Ah yes there is a "Thanks for your message" text - what kind of trigger do you use to fire that?
-
Its all about firing the event code at the right time and that depends on how your form works.
What happens after a successful form submission? Many times, you want to display a message along the lines of "Your Submission was Received", and that is when you want to fire off the GA code.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
GTM: Transaction value without tax as variable
Hi Mozzers, I'm trying to create a GTM variable for transaction value without tax. There is no datalayer field for this at the moment. e.g. I only have these fields in the datalayer: Revenue (€19.99) Tax (€3.47) Price (€19.99) No field with the price without tax. Is there a way to create a variable? Is it possible to work with a specific function? Or is it standard to implement an extra field in the datalayer? Many thanks,
Reporting & Analytics | | WeAreDigital_BE
Sander0 -
Do lots of event tracking via tag manager will it slow down my site?
Hi All, For my Ecommerce site I have done lots of tracking total I do have total 45 event tracking but many times one event, track many pages. So if visitors click on url or button then do my site speed affect because of these trackings? Thanks!
Reporting & Analytics | | pragnesh96390 -
Track PDF's in Google Analytics
Hi Mozzers, Is it possible to track PDF's via Google Analytics/Google tag manager? I'm not only looking for PDF downloads but for the actual activity when someone opens an interactive PDF document. So would it be possible to have onclick events on buttons in the PDF etc... Many thanks!
Reporting & Analytics | | WeAreDigital_BE
Sander0 -
How can I make sure that we are only tracking for single URLs?
Is there a way to track in Google analytics where part of the URL is excluded. For example, we need to track when customers complete an application form, however whenever a new form is completed a new URL is created. This makes it difficult to track pages in GA as there are so many URLs.
Reporting & Analytics | | Sable_Group0 -
URL String Tracking Question--Need help!
I am doing some research for a freelance project and found a URL receiving a decent amount of traffic from search with this url string after the normal page url (xxx.com/credit-card-counseling.aspx?match=e&query=debthelper.com&id=22097628847&id=1810807655) Is this some sort of GA tracking code? Why would it be used on that page to track organic search hits if that happens automatically? Would love some help figuring this out! Thanks,
Reporting & Analytics | | RickyShockley0 -
GA Goal Tracking for Proactive Chat
Hi all, Just wondering whether anyone knows how I'd be able to track Proactive Chats as a goal in Google Analytics? So when someone visits our site, and we proactively contact them by initiating a chat (rather than a reactive chat where the visitor initiates it). Thanks!
Reporting & Analytics | | AdrianCordiner0 -
Cover my tracks / two websites on the same Analytics
Hi, I've got 2 websites and I like one of them to make some links to the other one. These two sites are on the same Google Analytics account. They have been set up 3 month ago and they have some articles on them. I've heard that Google can see that those websites are related in my Analytics and use this information to give less power to the link I could make between them. What do think about it and what do you recommend me ? Shoud I closed the Analytics account ? Or down one of the website and rebuilt it whith a different domain / host / analytics ? The thing is if I delete one of the website i'll be force to republish the articles, because there are links on it, and they're part of a deal I've already made. Thank you
Reporting & Analytics | | Spleen0 -
Keyword tracking using Advanced Segment
I would like to see visits for only and only the following 2 keywords using advanced segment in GA. logo design india and logodesign Here's how i set up the Advancned Segment - Keyword > Matches Regular Expression > logo design india|logodesign The problem is that advanced segment report is also displaying visits for keyword thelogodesigns. Have i set it up correctly ?
Reporting & Analytics | | seoug_20050