Updates to Google Analytics in Blackbaud Sphere
On Thursday June 14, 2012 we released an update to how we implement Google Analytics in Blackbaud Sphere. In older versions of the Google Analytics code snippet, it was suggested that the code be placed before the closing body tag in the page. Google recommends that newer versions of the code snippet be placed before the closing head tag in the page. As a result we have updated the CMS Administer > Add Ons > Google Analytics field so that it is now inserted before the closing head tag in CMS pages.
What does this mean to you? First, if your organization was adding custom HTML, other than Google Analytics code, to this field it may no longer render correctly. Second, you will want to insure that you are using a newer version of the Google Analytics code. If you are using the traditional Google Analytics code there is a possibility that tracking may be interrupted.
How can you tell what version you are using? It’s fairly easy to tell by looking at the code itself. Newer versions will look something like this:
<script type=”text/javascript”>
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-XXXXX-X']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement(‘script’); ga.type = ‘text/javascript’; ga.async = true;
ga.src = (‘https:’ == document.location.protocol ? ‘https://ssl’ : ‘http://www’) + ‘.google-analytics.com/ga.js’;
var s = document.getElementsByTagName(‘script’)[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
Note the presence of “document.createElement” and “document.getElementsByTagName”. You will not see that in the traditional Google Analytics code.
Older versions will have two distinct script tags and will look more like this:
<script type=”text/javascript”>
var gaJsHost = ((“https:” == document.location.protocol) ? “https://ssl.” : “http://www.”);
document.write(unescape(“%3Cscript src=’” + gaJsHost + “google-analytics.com/ga.js’ type=’text/javascript’%3E%3C/script%3E”));
</script>
<script type=”text/javascript”>
try{
var pageTracker = _gat._getTracker(“UA-xxxxxx-x”);
pageTracker._trackPageview();
} catch(err) {}
</script>
The Blackbaud Sphere product team is committed to continuously improving the Blackbaud Sphere platform. This update allows us to keep pace with Google’s recommendations and utilizes a much more efficient model for implementing their tracking code. Google Analytics can provide a wealth of information about your site visitors, so happy data mining!
You can keep up with us on Twitter by following @bbsupport; we use the hashtag #bbsphere when we discuss Blackbaud Sphere. Take a look at our Twitter Guide for more info
-
http://blog.lwr.org/author/druth/ Dan Ruth
-
Allan Benamer
Similiar Posts
- New Google Analytics Available to Everyone
- Blackbaud NetCommunity 6.35 New Features: Unformatted Text Part
- Upgrading from Blackbaud NetCommunity 6.10/6.15: JQuery and Javascript Update Expectations
- Using Google Analytics to Get More Out of The Patron Edge Online
- Determine the Effectiveness of an Online Advertising Campaign

Subscribe to the RSS feed
Follow @BBSupport on Twitter
Follow Blackbaud on Facebook 



