19dc6cc169b4bfa2f153c8743b74744d0bd9a5d1
hiram
  Wed Sep 24 14:55:02 2014 -0700
I dont think it matters, but google says the require displayfeatures is supposed to be between create and send statements refs #13120
diff --git src/hg/lib/googleAnalytics.c src/hg/lib/googleAnalytics.c
index b21b625..636ed2a 100644
--- src/hg/lib/googleAnalytics.c
+++ src/hg/lib/googleAnalytics.c
@@ -1,39 +1,39 @@
 /* Copyright (C) 2014 The Regents of the University of California 
  * See README in this or parent directory for licensing information. */
 
 #include "common.h"
 #include "hgConfig.h"
 #include "hPrint.h"
 #include "googleAnalytics.h"
 
 
 void googleAnalytics()
 /* check for analytics configuration item and output google hooks if OK */
 {
 static boolean done = FALSE;
 
 if (done)
     return;
 
 done = TRUE;	/*	do not repeat this by mistake	*/
 
 char *analyticsKey = cfgOption("analyticsKey");
 
 /*	if config is missing or empty, nothing happens here	*/
 if (isEmpty(analyticsKey))
     return;
 
 /* updated to Universal Analytics code 2014-06-19 */
 
 hPrintf("\n<script>\n"
 "  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){\n"
 "  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),\n"
 "  m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)\n"
 "  })(window,document,'script','//www.google-analytics.com/analytics.js','ga');\n"
-"  ga('require', 'displayfeatures');\n"
 "  ga('create', '%s', 'auto');\n"
+"  ga('require', 'displayfeatures');\n"
 "  ga('send', 'pageview');\n"
 "\n"
 "</script>", analyticsKey);
 
 }