adding Google Analyticstracking Code in WordPress
How To Google Analytics Tracking Code in WordPress
Hello everyone! Today i’m gonna show you how to add Google Analytics Tracking Code in a WordPress blog. If you are keen on -by how many visitor your page is visited- like me this tool will remove your worry.Let’s do it!
Step -1- Login Google Analytics
Step -2- Click “Admin” tab on right top
Step -3-Click under “accounts” tab to your account until you see “Tracking Info” tab.
Step -4-Copy your tracking script and paste in an empty PHP file, then rename that file as analyticstracking.php
Step -5-Upload analyticstracking.php to your root directory(to includes) via an FTP client i.e: Filezilla.
Step -6- On your WordPress dashboard go to “Appearance >> Editor >> footer.php“
Step -7– Above </body> closing tag paste this code line <?php include_once(TEMPLATEPATH. ‘/includes/analyticstracking.php’); ?>
Finally save template and you are done.
Thank you very much for reading my article.You can search this article by searching for:
23 Mart 2014 at 23:28
I tried it but this doesn't work.
I added the php code just above body end tag in footer
My site started showing the the entire script at the footer. 🙁
23 Mart 2014 at 23:30
if so, add tracking code itself only without creating a PHP file