Adding Google Analytics to Orchard Core CMS

So this will be a quick and easy blog post, but if you try to google it (prior to this post) you won’t find any information on how to add Google Analytics to Orchard Core.

I did it the simple way today, by adding the JavaScript code provided by Google Analytics into a Widget I have embedded on my CollectorOfJack.com website.

Because I already had a Widget on every page, using the theme for the blog, I just input the content into that widget.

  1. Navigate to your Admin site /admin
  2. Click Content Definition
  3. Click Content Types
  4. Next to RAW HTML click List Items
  5. Add your snippet of code into the HTML there. Mine looked like this:

image


There you go, a quick and easy way to embed the Google Analytics JavaScript into your page in Orchard Core.

Read More at weblogs.asp.net:443

Recent Comments

There are currently no comments. Be the first to make a comment.

Add Comment

Please add your comment by filling out the field(s) below. Your comment may need to be approved before it becomes visible.
Enter your first name for display with the comment
Enter your last name for display with the comment.
Enter your comment here.
If you can't type DNNRocks in, you can't post, plain and simple.
Submit Comment Cancel

Chris Hammond

Chris Hammond is a father, husband, leader, software developer, photographer and car guy. Chris focuses on the latest in technology including artificial intelligence (AI) and has spent decades becoming an expert in ASP.NET and DotNetNuke (DNN) development. You will find a variety of posts relating to those topics here on the website. For more information check out the about Chris Hammond page.

Find me on Twitter, GitHub and LinkedIn.