.

MIT Libraries

Web Guidelines: MIT Libraries

Google Analytics

As of February, 2008, we have finished placing an SSI into every page on the Libraries site, to include the GA code.

How to see the stats

Go to:
http://google.com/analytics/

How to sign in (MIT libraries staff only)

Click on "view reports" next to "libraries.mit.edu."
Try the "content drilldown" section under "content" in the left nav bar.

 

How to add the code to a new page

To add it to Dreamweaver-template based pages (e.g. subject guides), download & apply the current template. For anything else, add this code:

<!--#include virtual="../googleanalytics.txt" -->

just before </body> in your page's code.

If the page is in a sub-directory, of course, the code should indicate a deeper page - eg:

<!--#include virtual="../../googleanalytics.txt" -->

To test the code, upload it to the -test directory and View Source. If the SSI is spelled and placed correctly, you should see, at the bottom of the source page,

<script type="text/javascript">
_uacct = "UA-1760176-1";
urchinTracker();
</script></BODY>

</HTML>

If the SSI is set up wrong, you'll get a visible error message on the non-source page. (What's SSI?)