Archived topic
Google Analytics Setup
5 replies · Started by Sumit on September 27, 2018
Hi I am wondering how you suggest that I setup Google Analytics if I am using Generate Press Theme.
Few concerns I have here are,
I am using Tag Manager and I have that setup using Generate Press.
So Technically I can setup analytics using tags manager.
But I also have Analytics Pro plugin by woo-commerce which is taking care of woo-commerce side of things.
What I would like to do is setup Google analytics in Theme, in such a way so it takes care of everything else except for woocommerce side of it, since everything in woo-commerce is being taken care of by their pro plugin.
Thanks.
Hi there,
this is not really Theme related, i assume you could apply exclude filters within your Google Analytics so they don't capture the Woo content?
thats why I am asking, is there a way for GeneratePress to control the pixel in such a way so it doesn't fire on woo-commerce content. At analytic level will have to mention many URLS.
Maybe I can create an elment for analytic pixel so it do not fire on woo-commerce content?
So you could use the Hooks element to add your GTM script and set the display rules to the entire site, and then exclude the Product pages:
https://docs.generatepress.com/article/hooks-element-overview/
where should be the hook location?
So the first script goes in the WP_head and the second closing script can go in the before_header