When i want to have google Analytics on my page ive got wrong messege on page:
string(114) "Smarty error: [in tpl_head:43 line 11]: syntax error: unrecognized tag 'var' (Smarty_Compiler.class.php, line 590)"
Here is the code i use in the <head>
Code: Select all
<__script__ type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-2422577-4']);
_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>