![]() |
Google Analytics in the Archive (and Forum)
1 Attachment(s)
New Version 2.0
New in 2.0: New Improved Google Tracking Code, Code in forum moved to recommended location before the </head> tag. Uninstall old versions before installing Version 2.0 You will need your Google Analytics tracking ID when installing or upgrading. (UA-XXXXXX-X) The main purpose of this mod was originally to add your Google Analytics code to the archive. The archive traditionally gets overlooked because the standard instructions of copying your analytics code into the footer doesn't cover the archive. You simply copy and paste your tracking ID into the mod and enable it in your forums and/or archive. To confirm it is working go to your archive and view the source on any archive page. At the bottom directly above the VB Copyright info should be your google code. I have tested this in 3.8.6 and 3.8.7 and it will work in all 3.8.x and probably in 3.7 and earlier as well. For VB4.x see this version: https://vborg.vbsupport.ru/showthread.php?t=256325 You won't see any indication on the pages but you can demo the product at: http://www.juot.net/forums/archive/index.php (You will have to view source to confirm it is working.) Please mark as installed if you use this. :) Full instructions in .zip file. |
hello
you don't need a plugin to do that just open the index.php file in the archive folder , and place the Google Analytics script at the end of it , and voila ! the code is working like a charm in all the archive pages |
cool... I will update the mod but I think it's important to keep so people don't forget to do this.
|
Prefer this trick.
For when I upgrade my vBulletin, will not have to worry about changing the file on hand. Thanks! Installed |
Quote:
Thanks! |
No...
In index.php look for the code: Code:
$output .= " Remember you will need to redo this each time you upgrade vbulletin if you do it this way. Also you will have to 'escape' every double quote in the google code with a slash \ as explained in the top post. EDIT- Actually it might work at the very very end of the file, AFTER the php closing tag too... I haven't tested it but that should work and no need to escape the quotes. But it wouldn't be valid HTML because all the code should be before the </html> so it may not work in all browsers. |
Great work (not that you need to be told :p) mate, will install when I've got a little spare time.
Cheers. |
Quote:
|
Even if I put the code in my template, it looks like Analytics is unable to get the traffic data from the forum...anyone with the same problem?
|
1 Attachment(s)
I go to Google Analytics -> Content Overview -> Full Report and do a search for "archive" and I see a bunch or archive URLs so i know it's working...
I suppose it's possible if the code wasn't escaped properly you might not got it to work... I will upgrade this from a plugin to a real installable mod so people don't have to escape the code themselves... Also you made sure to wait 24 hours before checking your analytics? |
Update!!
I have upgraded this to an installable product, you simply install like any other product, copy and paste your Google Analytics code. If you have the old plugin installed delete it first before installing this product. Full instructions in the zip fie. |
Great, installed.
|
Updated. I'll wait another 24hrs...let's hope it works this time :)
|
If you have a link to the forum I can check...
|
Quote:
|
There seems to be an error on your archive page: http://www.upsblogit.com/newforum/archive/index.php
I see the code fine in your regular footer, not sure if it's from the mod or you manually put it in your footer. Please see if you disable the mod on the archive if it goes away? |
FYI - I made a very minor change and released version 1.13... All it changes is the output formating of the code for easier debugging in case of a problem.
|
Quote:
|
Quote:
|
Quote:
|
Ok, I disabled each plugin, one by one, but the error is still there >:(
damn...I remember that, following some guides, I added the Analytics script in the footer and in another page, but I'm unable to remember WHERE... |
I suggest you try disabling hooks to confirm where the problem is. There are no templates in the archive.
To disable hooks edit your config.php... add this as the second line, directly below the opening tag <?php Code:
define('DISABLE_HOOKS', true); |
Ok, no more error removing the hooks. Consider I don't even know what is a hook :'(
Now what to do? What changes if i remove hooks? |
Disabling hooks *really* disables every single mod and plugin... You should re-enable them again but now we know for sure the problem is with a plugin, not altered vbulletin files.
Re-enable your hooks, confirm the error is back... Then go to Admin CP -> Plugin Manager and tell me what plugins you have at the top under Product: vBulletin (if any)... |
Sh*t, found it!
It was my fault as I looked at Products instead of Plugins... it was this one: Name: Code in Archive Hook Location: archive_complete PHP Code: $output .= "<script src=\"http://www.google-analytics.com/urchin.js\" type=\"text/javascript\"> </script> <script type=\"text/javascript\"> _uacct = \"XXXXXXXXXXXXXXXXXXXXXXXXXXX\"; urchinTracker(); </script>"; <!--Paste Google Adsense Code (with slashes) Above This Line--> '; |
yeah,, good, delete that plugin, you won't need it anyway with this mod.
|
tankx :-)
|
installed but google tells me that no tracking is installed?
www.NJStangers.org I don't see it on my pages neither even though its in the google anayltics product I added to the backend |
It's definitely in your archive... I see it's not on your pages though... I think it's because you have the "Branding" removed from vBulletin (branding free license)- I wasn't taking that into consideration when I tied the Analytics code to the copyright... If there's no copyright there's no analytics code.
I suggest you manually add the code to your footer template but leave the mod installed for the archive. I'll work on fixing this. |
ah okay that happened when we did the custom garage as well as a few other mods, that explains it. Thanks again.
|
Quote:
|
Uploaded version 2.0.
Now uses newer, better Google Javascript code. Tracking code now in the Google recommended location (before </head>) You now enter only your Tracker ID into the mod settings, not the whole code. I suggest everyone upgrade to new version at their convenience, |
Update installed.
Thanks for keeping the mod current! D. |
good! thanks!
|
Does anyone know how to get the new version of google analytics to show "Guests" or those not logged in using their realtime overview?
|
This needs an update with adjusted bounce rate: http://www.hmtweb.com/marketing-blog...gle-analytics/
|
All times are GMT. The time now is 05:31 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|