Created
April 18, 2013 08:56
-
-
Save hito-asa/5411285 to your computer and use it in GitHub Desktop.
Revisions
-
Hitoshi Asai created this gist
Apr 18, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,18 @@ var _gaq = _gaq || []; var pluginUrl = '//www.google-analytics.com/plugins/ga/inpage_linkid.js'; _gaq.push(['_require', 'inpage_linkid', pluginUrl]); <c:if test="${!gaq.suppressLogging}"> _gaq.push(['_setAccount', '<%= GA_PROPERTY_ID %>']); _gaq.push(['_setSiteSpeedSampleRate', 30]); <c:forEach var="v" items="${gaq.customVars}" varStatus="status">_gaq.push(['_setCustomVar', ${f:h(v.index)}, '${f:h(v.name)}', '${f:h(v.value)}', ${f:h(v.scope.value)}]);</c:forEach> <c:choose> <c:when test="${gaq.customUrl != null}">_gaq.push(['_trackPageview', '<c:out value="${gaq.customUrl}" />']);</c:when> <c:otherwise>_gaq.push(['_trackPageview']);</c:otherwise> </c:choose> <c:forEach var="e" items="${gaq.events}" varStatus="status">_gaq.push(['_trackEvent', '${f:h(e.category)}', '${f:h(e.action)}', '${f:h(e.label)}', ${f:h(e.value)}, true]);</c:forEach> </c:if> (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); })();