Joomla Stack Exchange is a question and answer site for Joomla! administrators, users, developers and designers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a client who has contact forms on 5 different pages.

We would like to track the submissions for each page with Google Analytics in a way that allows to track from which specific page the users submitted.

How is this best set up?

share|improve this question
up vote 6 down vote accepted

You can implement Analytics Event Tracking (E.g. Click on Contact Button).

<a href="#" onClick="_gaq.push(['_trackEvent', 'Contact', 'Confirmed', 'First ever contact']);">Submit</a>


As an alternative, you can add Javascript source code in each contact page. As the simplest posible way, you can install NoNumber Sourcerer (, and a snippet like this to associate the event with the button:

jQuery( '#ContactButton' ).click(function( event ) {
  _gaq.push(['_trackEvent', 'Contact', 'Confirmed', 'First ever contact']);
share|improve this answer
How would we set this up to know from which specific page the form was clicked? – NivF007 Jun 13 '14 at 2:03
you can send in different values where 'Contact' and 'Confirmed' are for different pages. Check the documentation in the link NivF007 provided. When I set it up it took some trial and error to get it reporting the way we wanted. – ContextSwitch Jun 13 '14 at 2:11

Google Analytics Event Tracking is the way to go. Here is a tutorial on how to setup. You can put the onClick code in the button or input you are using for Submit.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.