Google Analytics code in 2.9.1 [SOLVED]
After upgrading to the latest version of Contao (2.9.1) I've:
- created a moo_analytics template and edited my UA code
- added the template at the bottom of the moo_ template list to my page layouts
- logged out of the back end
But I still can't see the Google Analytics code in my page source.
What step am I forgetting ?
Peter
Re: Google Analytics code in 2.9.1 [SOLVED]
I've found it.
In my front end template I had
Code:
<?php echo $this->motools; ?>
after the
tag. After moving it to the top of the template, just before the
tag, and removing all sorts of hardcoded javascript tags, things started working again.
Lesson learnt: when moving from a site designed for Typolight 2.6 in one go to Contao 2.9.1 there are all sorts of side-effects in earlier designed templates to look out for.
Documentation on how to create a proper front end template yourself is very limited in the User manual, and the video showing how to do it doesn't show any of the advanced features and is from version 2.2. Perhaps some time should be spent on up-to-date documentation for the latest and greatest Contao revision!
Peter