I am new to magento and I have placed my account number in my system > Configuration > Sales > Google API. I have also enabled Google Analytics. But still I can't see the Google Analytics code on any of my magento application. What I have double checked are:
Same here. It turns out that the problem was caused by my customized theme that was developed for magento 1.5 and now is applied to 1.7.
In app/design/frontend/mytheme/layout/googleanalytics.xml i had:
<block type="googleanalytics/ga" name="google_analytics" as="google_analytics" />
And it should be:
<block type="googleanalytics/ga" name="google_analytics" as="google_analytics" template="googleanalytics/ga.phtml" />
Have just checked and the google analytics code is normally placed in the after_body_start
block.
If that block isn't used in your theme or if you just want to follow better practices change that to before_body_end
. You can find the file "googleanalytics.xml" in your theme's layout directory or in app/design/frontend/base/default/layout
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With