search
AI OnAI Off
A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More.
If you are using the GA plugin from the EPiServer Add-Ons, you actually only need this in the bottom of the layout:
@Html.Raw(Html.RequiredClientResources("Footer"))
Optionally, you could manually get the GA script using this:
@Html.AnalyticsTrackingScript(currentPage)
If you look at the developer guide for the GA module for CMS 6 R2, they briefly mention how to use it in MVC:
Thanks Chris.
I missed that line when I read through the documentation.
Hi
We are using MVC4 on our EPiServer 7 CMS project and want to add the Google Analytics plugin.
However, as the plugin documentation mentions only the web forms implementation, I am wondering how we output the GA Script when using _Layout.cshtml and Razor syntax.
Is it possible for us to use the GA Plugin with MVC and Razor syntax?
Martin Graney