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
-
Can Segment capture organic traffic? If so is it more reliable than Google Analytics?
Hi mozzers, We just learned that our standard GA hasn't been as reliable as we hoped so and we are trying to find other ways to track organic sessions. Which solution would you consider? Is Segment one of them? If so, is it more reliable than Google Analytics? Thanks
Reporting & Analytics | | Ty19861 -
Search and Replace filter on Google Analytics?
Hello! On our GA account for one of our clients, we'd like to add a search and replace filter to the Views section of the account. The URL is www.askergoworks.com (it redirects to askergoworks.com), and Google has flagged us to have redundant hostnames. This is why we'd like to add the filter. Would the regular expression be askergoworks.com|www.askergoworks.com ? Any help would be great - I'm not a regex expert, so I really don't how to go about this. Thanks!
Reporting & Analytics | | AGILITY0 -
Google Analytics shows most referrers as "Direct" -- What are some better tools?
Very often Google Analytics will show 50-90% of our referrers as (direct) which is not very helpful. Are there other tools out there that will provide a clearer breakdown of what other websites are sending us our traffic? Specifically, I want to be able to be able to tell who are the top traffic referrers to my top performing pages on my site for the last 30 days. (I want to be able to study this on a per-page basis.) Thanks in advance!
Reporting & Analytics | | Brand_Psychic0 -
Why my WMT is showing more clicks than my Google Analytics Organic Search Traffic?
Hello Everybody, Can somebody help me figure out this puzzle: My WMT is showing 6000 clicks, while my Organic Traffic in Google Analytics is showing only 3500 daily ... how is that possible? Best Regards
Reporting & Analytics | | Muhammad_Jabali0 -
Google analytics Goals and Funnels??
Hey - how's things? I've got 2 goals setup, each of which use the same thank you page but with different required funnels. The results have been identical for the last few weeks - which tells me I've got something wrong!! The first goal has a contact form on every page in the /products/ directory set up like this:
Reporting & Analytics | | agua
destination equal to: /thanks-enquiry/funnel step1 page: ^/products/.* required: yes The first goal has a form on 1 page called /on-sale set up like this:
destination equal to: /thanks-enquiry/
funnel step1 page: /on-sale required: yes Any ideas?0 -
Google Analytics - In-Page Analytics
I had a strange thought waking up this morning, and was curious to hear other people's opinions on it. In Google Analytics, under Content > In-Page Analytics, Google shows what links on your site pages get clicked and how many times plus other metrics. Do you think they use that data for ranking back links so-to-speak? What I mean is, say I had a back link to my site on example.com, and example.com had google analytics installed. Google can see through google analytics whether my link has been clicked on. Say that my link gets no clicks, do you think that Google would use that metric against my site deeming it "not popular" or "not a good resource", even if example.com was a very popular site? And it could work the other way. Say my link got thousands of clicks on example.com, do you think that Google might use that to promote my site? I couldn't find any other discussion on this anywhere, so am not sure if people have already thought about this.
Reporting & Analytics | | THB0 -
Omniture vs Google Analytics
What's your opinion on analytics tools? Specifically Omniture vs Google Analytics. Is Omniture really that much more powerful than GA? Have you used GA Premium, the enterprise package? My main question - Can GA (free or premium) do everything that Omniture can? If GA Premium and Omniture were the same price, which would you choose? Is one harder to implement, pull reports, tweak, ect? Thanks in advance.
Reporting & Analytics | | akim260 -
Should you get a new Google Analytics account if your site has a new domain after a site redesign/new development?
We recently developed a new site for a client and they have opted to move forward with a domain change. Should we create a new Google Analytics account for the new site?
Reporting & Analytics | | TheOceanAgency0