Google Analytics is an incredibly powerful and easy-to-use tool that can help you better manage and understand your web portal’s usage.  And most of its functionality is free!  Adding Google Analytics to your CloudPortal Services Manager web site is a straightforward process that just requires a little bit of inside knowledge.

There are many web analytic tools available nowadays, and I’m not espousing one over the other.  I’m using Google Analytics only as an example since I’m more familiar with it.  The tips in this article can also be used with other web analytic tools.

What Is It?

You will be able to see both real-time and historical information about things such as which web pages are most active, where users navigate to next, how long the users remain on each page, and where the users are located.  In other words it lets you analyze the Who, What, and Where of your web site’s users.  Based on this you will be able to see where the users’ interests are, and potentially convert that into sales.

How Does it Work?

First you sign up for a free account, at which time you’ll get a Tracking Id.  By adding this Tracking Id and a little bit of Javascript code to your CloudPortal Services Manager web site you’ll be able to instantly view your web site’s usage.

For instance you’ll be able to view real-time information:

It also allows you to view historical information:

This is just scratching the surface.  By digging deeper into its interface you’ll be able to analyze metrics such as language and location demographics, behavior (new vs returning, visit duration, bounce rate, etc…), what type of browser and OS they’re using, etc.  You can also customize it with your own metrics.

What Are the Steps?

To get started just follow these steps:

  1. Sign up for Google Analytics at http://www.google.com/analytics/
  2. Go through the sign-up process:
    1. Type in the external web address for your CPSM web site.
    2. Get a Tracking Id. Example: “UA-44444213-1”
    3. Copy the tracking Javascript code.
  3. Now modify the “Main.Master” file in CPSM by adding the Javascript code at the top. This is a template that forms the basis of almost every CPSM web page.

Let’s go through this in more detail.

When I signed up for Google Analytics I typed in the web URL of my CPSM environment.  It then gave me a tracking Id as well as some javascript code.  Here’s an example of the Javascript code:


<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-44444213-1', 'citrite.net');
ga('send', 'pageview');
</script>

We want to add this Javascript code to every web page in CPSM.  For CPSM v11 we’ll navigate to C:\inetpub\Cortex Management\CortexDotNet\Common\ and then open the Main.Master file in Notepad (after first making a backup copy of this file). You’ll see that near the top of the file there are already some <script> tags in the <head> section. We’re going to paste our Javascript tracking code anywhere within the <head> section; in my case I put right after the existing in-line Javascript code. Save it and exit.

Next, open up a web browser and browse to your CPSM web site.  After logging in use your browser’s “View Source” functionality to verify that the code we pasted is now included.  That’s it, we’re done!  We didn’t even need to restart the web server.

Go back to Google Analytics and you can start looking at the Real-Time information immediately.  For the historical information you’ll need to wait till tomorrow.

What’s Next?

We’ve really only scratched the surface of what we can do. At this point it’s probably best to learn more about Google Analytics itself, and to better understand what it’s capable of. Then you can do things like add Event Tracking to your CPSM web site. For instance you might want to track every time that someone clicks on the “Provision” button. The rest is really up to you and how much data mining you want to do!