[RESOLVED]Does anyone know how to track www.mysite.com/1 vs. www.mysite.com/2 ?


I’m looking for answers for this question, but have not come across anything helpful. Thought maybe someone from this forum could help?

We’re building a MVC3 web app, with C#. The app allows users to create a poll, and to access each poll, we go to:

www.mysite.com/Poll/Take/1 or


with 1 or 2 being the PollID.

Now – we need to add some tracking to each of these pages; and report the data back to the user who created them.

In order to do so, we are looking at our options for web analytics; but we are not clear on how to differentiate the 2 urls above?

Does anyone have similar experience and want to share some advice? it does not matter which tool you are using (Google, Yahoo, Piwik, or others) – we just want to understand the concept first; and if it can be done; and the level of effort.



Update – I am looking into Google Analytics and Piwik as potions to use. If anyone has any idea on the next 2 questions, please sound off:

1) For Google Analytics – is it true that I only need 1 set of tracking code for ALL pages on 1 website? so I do not need a different "GA ID" for the 2 scenarios that I described above?

2) for Piwik – Is there a way to programmatically "add a website"? The FAQ page mentioned that I can go into the "admin area" to add a website (URL), however, I need to be able to do this programmtically….and I have not seen any topic on this from their

Or, using Piwik, is it true that I only need add 1 website for "www.mysite.com"? and the many pages like "www.mysite.com/Poll/Take/1" will just be tracked by default? I’m not sure about this from reading their docs, want to know if anyone has used it and
would know?

Many Thanks!

With GA you just put your ID in the script and include it on every page and that’s all you need for the basics.  The admin tools will show you how many people visited each url and a whole bunch of other stats.  If you want more targeted stats and tracking,
you can add extra code to "push" events to GA.  So you could trigger an event each time someone selected the answer for a question.  That way it will show you how many people answered Q1, how many Q2 and so on, so you can get stats not just on how many people
hit the page, but how far on average people got before abandoning it, and how many actually completed it.

At its most basic level though, just stick the script on every page and you’ll still get a look of meaningful info.

Leave a Reply