<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Gravity Support Forums Topic: Google Analytics and conversion tracking with ajax</title>
		<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax</link>
		<description>Gravity Support Forums Topic: Google Analytics and conversion tracking with ajax</description>
		<language>en-US</language>
		<pubDate>Mon, 20 Apr 2026 03:03:00 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/google-analytics-and-conversion-tracking-with-ajax" rel="self" type="application/rss+xml" />

		<item>
			<title>waynekolenchuk on "Google Analytics and conversion tracking with ajax"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax#post-96594</link>
			<pubDate>Wed, 28 Nov 2012 13:03:59 +0000</pubDate>
			<dc:creator>waynekolenchuk</dc:creator>
			<guid isPermaLink="false">96594@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I added the code snippet here (&#60;a href=&#34;http://www.gravityhelp.com/forums/topic/onclick-tracking#post-7734&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/forums/topic/onclick-tracking#post-7734&#60;/a&#62;) to functions.php and changed the form ID. JQuery is available, and the GA tracking code  is in the site header.&#60;/p&#62;
&#60;p&#62;The form submitted properly but the Ajax response I saw was the one I set up in the plugin instead of &#34;Nice! Your successful form submission was recorded by Google Analytics&#34;.&#60;/p&#62;
&#60;p&#62;I did get the email from the form, but I don't see it reported as an event in GA. Can you please point me in the right direction?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>JuicyResults on "Google Analytics and conversion tracking with ajax"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax#post-74255</link>
			<pubDate>Thu, 06 Sep 2012 16:43:38 +0000</pubDate>
			<dc:creator>JuicyResults</dc:creator>
			<guid isPermaLink="false">74255@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;David,&#60;/p&#62;
&#60;p&#62;A belated thanks for the reply. I am not afraid of adding stuff to functions.php but the solution in the link that Stan posted assumes you only have one form (and are doing event tracking but I assume you could swap out trackEvent for trackPageview)...I'd have to get someone to code it to work with my many forms without pasting the code in there for each form. But definitely something to look into.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Peralty on "Google Analytics and conversion tracking with ajax"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax#post-71459</link>
			<pubDate>Fri, 17 Aug 2012 10:22:44 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">71459@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Juicy - iframes only see the code within the iframe, that's why you had to add more to it to get things to work. It shouldn't have worked before, so I am not sure why it did. You shouldn't be worried about having it in there &#34;twice&#34; because again, the iframe is seen as independent of the page it is being pulled into. &#60;/p&#62;
&#60;p&#62;The link that stan linked is the best way to do things. &#60;/p&#62;
&#60;p&#62;Stan- I am not sure why you don't like the functions.php solution, but it is effective, and uses our built-in hooks system. If you could give me more information on how you would like to see it work, I'd be happy to pass it on to the developers.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stanvdmaarel on "Google Analytics and conversion tracking with ajax"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax#post-71453</link>
			<pubDate>Fri, 17 Aug 2012 10:05:45 +0000</pubDate>
			<dc:creator>stanvdmaarel</dc:creator>
			<guid isPermaLink="false">71453@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Same here! Looking for a workable way for tracking conversions either by event tracking or virtual URL. Whatever works best! &#60;/p&#62;
&#60;p&#62;As a non-techie I just don't like the need for adding PHP code to functions.php as a &#34;solution&#34; here: &#60;a href=&#34;http://www.gravityhelp.com/forums/topic/onclick-tracking#post-7734&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/forums/topic/onclick-tracking#post-7734&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Thx,&#60;/p&#62;
&#60;p&#62;Stan
&#60;/p&#62;</description>
		</item>
		<item>
			<title>JuicyResults on "Google Analytics and conversion tracking with ajax"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/google-analytics-and-conversion-tracking-with-ajax#post-71333</link>
			<pubDate>Thu, 16 Aug 2012 13:06:20 +0000</pubDate>
			<dc:creator>JuicyResults</dc:creator>
			<guid isPermaLink="false">71333@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I have researched this problem thoroughly on the forum and am still confused. (Note: I am talking here about ajax forms, where confirmation is on the same page and no redirect to a confirmation page.)&#60;/p&#62;
&#60;p&#62;I am been able to successfully track GA conversion goals (not talking events here but goals) by placing something like this in the confirmation:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;&#38;lt;script type=&#38;quot;text/javascript&#38;quot;&#38;gt;_gaq.push([&#38;#39;_trackPageview&#38;#39;,&#38;#39;/tla-thankyou&#38;#39;]);&#38;lt;/script&#38;gt;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;In the latest site I did this with, I am now getting a &#34;_gaq is undefined&#34; type of error when I submit the form and look at my console. Okay, I understand that the form is loading in an iframe and that possibly my code in the confirmation does not &#34;see&#34; the variable defined in the header of my page (via the GA code normally pasted just before the closing &#60;code&#62;&#38;lt;head&#38;gt;&#60;/code&#62; tag. So I entered the full GA code (where the variable is defined) into the confirmation.&#60;br /&#62;
And that seemed to solve the problem.&#60;/p&#62;
&#60;p&#62;My questions are this:&#60;br /&#62;
1. Should I be worried about executing the full GA tracking code a second time? Once in the &#60;code&#62;&#38;lt;head&#38;gt;&#60;/code&#62; of my page and once in the iframe&#60;br /&#62;
2. Why do I need to add the full GA tracking code when I didn't before? Did something change with the latest version of Gravity Forms?&#60;/p&#62;
&#60;p&#62;It would be nice to have a simple answer once and for all the best method for those of us who wish to track virtual pages (and take advantage of the ajax form) - with some clear understanding for those of us who are not super technical EXACTLY what we should or should not be doing. So many of us choose Gravity forms because of the ease of creating lead gen pages (meaning we are marketers first, coders second) and need a reliable way of tracking form submissions in Google Analytics - one we can use over and over again. &#60;/p&#62;
&#60;p&#62;Any help will be appreciated.&#60;/p&#62;
&#60;p&#62;thanks,&#60;br /&#62;
Lisa
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
