Google Analytics/ Contact 7 Plugin
-
I have a site that uses the contact 7 plugin for its contact form sitewide in a sidebar and on a contact us page.
I've set up a goal in analytics and tracked using the "on_sent_ok" hook but the number of goals GA is creating is far outweighing the number of times the form is actually completed.
I figured my initial mistake was to use the contact-us page as the page tracker variable for the goal but wondered if it was counting all form completions AND anyone who went to the contact page.
So I amended it to a contact-us/thank-you page that no site visitor could navigate to, and since I have no goals completed, even though we're getting enquiries through the form.
Am I being dumb here and missing something quite simple?
-
Ah just noticed I have all code on 1 line so
on_sent_ok: "pageTracker._trackPageview('/company.com/contact-us/thank-you');"
should it actually be...
on_sent_ok:
_"pageTracker.trackPageview('/company.com/contact-us/thank-you');"
-
Hi SSC Davies
Yep, I have it set up just like that (I think I probably referenced the same page of content you've pasted in here when looking for the correct hook )
I'm not massively knowledgeable on javascript, but would other javascript on the page affect the function of the hook?
-
Hi Gareth,
using on_sent_ok should not be padding the numbers. Do you have it implemented as seen here :
JavaScript Action Hook:
on_sent_ok
Sometimes you might think of running custom codes after the form has been submitted. For example, you may wish to run Google Analytics’s tracking code for tracking their visitor’s usage of the contact form and counting it as conversions.
The new JavaScript action hook would be useful in such a case. If you have a JavaScript code you wish to run after form submission is completed successfully, simply insert the code into the Additional Settings section (which is new in this version and is placed at the bottom of the admin panel) with preceding
on_sent_ok
keyword, like this:Note that you need to quote the codes properly; and the code must be in one line.
To show you a more practical example, if you want to insert Google Analytics’s tracking function, enter it like this:
on_sent_ok: "pageTracker._trackPageview('/funnel_G1/step1.html');"
-
You're on the right track with where you are at now. You are setting up contact-us/thank-you page as your goal page, right? Well, is it possible that your form submission php script is taking people to this page and it is different than your other pages? As in it is just a line of text saying thanks?
If so, you may want to edit the form submission php code to include your Google Analytics code. Perhaps you aren't seeing any goals because the page they land on after submission simply doesn't have your GA code on it to count the completed goal. That would be my best guess.
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
-
Strange landing page in Google Analytics
Hello MOZ Community, The website in question is https://x-y.com/ When i looked at the landing pages report in GA , x-y.com is appended at the end of every URL like this. https://x-y.com/x-y.com When i open the above URL in GA interface, it shows page not found. This is obvious as there is no such URL.
Reporting & Analytics | | Johnroger
The metrics like sessions, Users, Bounce rate all look good. In the property settings, The default URL is written like this http:// cell-gate.com (Please note that s is missing in property settings). But how is traffic tracked correctly How do i solve this problem. What settings should we change to make the landing pages report look ok Thanks0 -
Recover/Claim Ownership of a Google Analytics Account in easy steps
Hi All, I just found this useful article on Recover/Claim Ownership of a Google Analytics Account , I've seen same question asked by website owners, webmasters very frequently in many forums so I decided to share the article. **No affiliation, sponsorship, nor any partnerships with ohow.co Thanks
Reporting & Analytics | | Alick3000 -
How to Configure Google Analytic API?
Hello All, I want to implement google analytic api can any one show me the whole process? Regards, Mit
Reporting & Analytics | | mit0 -
Question re Google Analytics and its more accurate alternatives
Hi guys There are two main issues we have with Google Analytics, and I'd really appreciate if anyone has the time to give an answer to that. We completely miss organic traffic data before 7/22/2013 although our account is active since 2005. Any thoughts on that? Is it the not provided move that swiped out all data or something else? Even for the data we do have there is lots of inaccuracies, and we are thinking on switching or at least adding a new analytics software, any recommendations? (FYI, it turns out we do not keep access logs on the server for more than 2 months, and we might fix that for future references, but now we are looking for external solution). Any help will be much appreciated Thanks Lily
Reporting & Analytics | | wspwsp0 -
Google Analytics subdomain ecommerce tracking flatlines :-(
Buongiorno from 19 degrees C wetherby UK 🙂 This website http://www.philpotts.co.uk/ contains a shop sub domian @ http://shop.philpotts.co.uk/. I configured the site Ga analytics code to include the subdomain (see below code). I had to do this as i was getting refferal data from the actuall subdomain. But after following the instructions on p117 of cutroni's ga book things have gone wrong, mainly now eCommerce data has dissapeared 😞 So my question is please: "Why has installing the GA code above caused eCommerce tracking to suddenly go dead?" Grazie tanto,
Reporting & Analytics | | Nightwing
David0 -
Google Analytic - Is it possible to see which organic keyword triggered goals?
Hi, I am trying to see which of my Google organic keywords triggered my goals? In GA I click > Conversion > Goals > Overview > Source Medium (This then says where my goals came from but when I click Google / Organic it just brings me to the overview page of my organic traffic). Is it possible to see which organic keywords trigger goals?
Reporting & Analytics | | AdvanceSystems0 -
Google Analytics Customer filters & the correct syntax
Good afternoon from torential rain and thunder Wetherby UK 😞 Ive been delving into the world of custom filters in Google analytics and Ive hit a problem. Apart from Googles advice being out of date (wont get into that one) I wanted to set up clone a profile of an existing site and set up a filter that would exclde USA traffic. But a country can be called many things e.g. United Sates USA America so how do you know what is the correct name to put in the filter pattern box? Here is a screen shot of my efforts :http://i216.photobucket.com/albums/cc53/zymurgy_bucket/filter-toexclude-usatrafficcopy.jpg (I chaned it to United States) So my question is where is there a list of the correct syntax for the filter pattern box? Taker for example you wnated to set up a custom filter to include just Palm OS traffic apprently from reading this the correct filter patter is Palm OS, i only know that from this http://www.e-nor.com/blog/web-analytics/tracking-mobile-devices-in-google-analytics Whilst Google has lots of documentation about filed patterns as documented here http://support.google.com/analytics/bin/answer.py?hl=en&answer=1034380&topic=1034830&ctx=topic Where in the name of flying spacial jockstraps is there documentation for the correct filter pattern syntax. Help my head hurts 😞
Reporting & Analytics | | Nightwing0 -
Advanced segements Google Analytics
Hi guys, I was to hasty last time marking the given question as answered. So i would like to ask another question on the subject. My original question was how to get a pdf report of 10 specific keywords with information about visits,pages per view. avg, visit time, new visitors and bounce rate. The answer was to create an advanced segment with "or operators" and adding all keywords on an exact match basis. I did this but it still gives me a list of more then 500 keywords in traffic sources organic view. Next to that i get different visitor numbers for some keywords where it says 40 at the normal segments (all visits) but gives me 0 when i turn on the advanced segment. I've been clicking and changing things for a long time until i got almost dizzy. Could someone plz help?
Reporting & Analytics | | 5MMedia0