Commit 3cff98b3 authored by Matija Obreza's avatar Matija Obreza
Browse files

Moved ga.jsp to bottom of pages

parent 214dd3d2
......@@ -50,5 +50,6 @@
<%@include file="footer.jsp" %>
<sitemesh:write property="page.javascript" />
<%@include file="ga.jsp" %>
</body>
</html>
......@@ -37,8 +37,6 @@
<script type="text/javascript" src="/html/js/tab.js"></script>
<script type="text/javascript" src="/html/js/crophub.js"></script>
<%@include file="ga.jsp" %>
<!-- Processing time:
<div class="footer clearfix" style="font-size: 80%"><spring:message code="page.rendertime" arguments="${springExecuteTime}" /></div>
-->
......@@ -10,10 +10,10 @@
ga('create', '${googleAnalyticsAccount}', 'auto');
var p={};
try {
if (_pageDim.institute != null) {
if (_pageDim && _pageDim.institute != null) {
p.dimension1=_pageDim.institute;
}
if (_pageDim.genus != null) {
if (_pageDim && _pageDim.genus != null) {
p.dimension2=_pageDim.genus;
}
console.log(p);
......@@ -25,7 +25,7 @@ try {
// Other trackers?
try {
if (_pageTrackers.length > 0) {
if (_pageTrackers && _pageTrackers.length > 0) {
for (var i=_pageTrackers.length-1; i>=0; i--) {
var trackerName='gat'+i;
ga('create', _pageTrackers[i], 'auto', {'name': trackerName});
......
......@@ -50,5 +50,6 @@
<%@include file="footer.jsp" %>
<sitemesh:write property="page.javascript" />
<%@include file="ga.jsp" %>
</body>
</html>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment