Dear All, we want to start tracking our only 3 adds on the bottom of our newspaper site (done in drupal 5) (we only have 3 adds :))
Basically, in the page.tpl.php file I have hardcoded each image as per below:
a onclick="javascript:urchinTracker('/bannerads/advertiser1/bottomLeft');" target="_blank" href="http://www.mysite.com"
For some reason though, my google analytics isnt picking any clicks up. I have clicked on the banners outside my own network on home PCs etc but still nothing in analytics which I search for content of /bannerads/
Is the way I have coded the link in page.tpl.php wrong or are there any other issues with coding links like this in a drupal site. I feel as if this isnt the best way to track links on my drupal sirte for newspaper. I would love to hear how everyone else does it for their newspaper sites as Im sure alot of them are built around the advertising model compared to my local one
Comments
First off, you should
First off, you should probably be asking this question on a group or mailing list somewhere that's related to Google Analytics. I'm not sure if Analytics really works that way indicated in your code sample, but I don't know any better.
Second off, the Advertisement module for Drupal does some nice ad tracking and other things. You should take a look at it.
Third off, do you spell "addvertisement" with two Ds as well?
The Boise Drupal Guy!
Garrett, thanks for the
Garrett, thanks for the help, that Advertisement module looks good, will take a play with it here now. Apologies for the bad spelling, i have been in front of the screen since 7am this morning :(
If you really want
If you really want sophisticated tracking for on site advertisements I would investigate the Open X adserver. It's GPL software and in addition to tracking gives a lot of flexibility in placement, how many impressions to serve, etc.
philly, thank you so much
philly, thank you so much for the OpenX comment, playing with it right now, I have so much to learn here, fascinating when someone points you to a powerful new piece of software like this to play with that you never knew existed.
For my 3 simple banners in block, i finally figured out how to track them for the benefit of anyone else who wants to track an ad or two on their newspaper site starting off -
a href="http://www.mylink.com" target="_blank" onClick="javascript: pageTracker._trackPageview('/bannerads/advertisername/bottomRight');">
<img src="bottomRight.jpg"
So many people out there have advised something totally different to the above. The Advertisement module was great as well
Also check out OpenX hosted
It's still in private beta, but you might be able to get it. http://www.openx.org/en/hosted
It's basically the same thing that you'll get through hosting it yourself only 1) you don't have to maintain it (yay!) and 2) you'll be able to enroll in their "OpenX Market" which allows other folks to bid on adspace (ala adsense).
Also worth checking out is Google AdManager. It's very similar to OpenX hosted, but I find it's a bit more confusing to setup than OpenX, especially getting the javascript includes set up properly in the headers.
I've been trying to use the
I've been trying to use the ad module, but can't get it to work and the documentation isn't too extensive. I entered an issue http://drupal.org/node/318060 but no response yet.
If anyone is using the advertisement module successfully I'd appreciate their help.
OpenX and Google AdManager look interesting. Does anyone know if you can track clicks on ads by username (ie when a logged in user clicks on an ad) with either of these?
Thanks