EndPointCorp / end-point-blog

End Point Dev blog
https://www.endpointdev.com/blog/
17 stars 65 forks source link

Comments for Virtual Page Tracking and Goals with Google Analytics #439

Open phinjensen opened 6 years ago

phinjensen commented 6 years ago

Comments for https://www.endpointdev.com/blog/2011/04/virtual-page-tracking-google-analytics/ By Steph Skardal

To enter a comment:

  1. Log in to GitHub
  2. Leave a comment on this issue.
phinjensen commented 6 years ago
original author: Anonymous
date: 2012-12-19T10:20:55-05:00

So it has to be implemented only in header (original tracking code) or html elements have to be changed as well? If they do, then how does it has to be done?

phinjensen commented 6 years ago
original author: Steph Skardal
date: 2012-12-19T11:47:20-05:00

This only needs to be implemented where the existing tracking is implemented (either in the header or before the tag). No HTML elements have to be modified for virtual page tracking.

phinjensen commented 6 years ago
original author: Anonymous
date: 2012-12-20T07:37:24-05:00

Thank you very much for the answer. Just one more question: is it possible to replace _gaq.push(['_trackPageview']);with _gaq.push(['_trackPageview', '/customURL']) instead of adding it? Because if both of them are there then count of pageviews in reports is doubled.

phinjensen commented 6 years ago
original author: Steph Skardal
date: 2012-12-20T09:16:46-05:00

Yes, replacing the line is what is indicated by the diff in the example above (-: remove one line,+: add another line).