Forum Moderators: martinibuster
Now at the start of the week I'd made some modifications to the site software, in the course of which I'd temporarily managed to switch off some of the AdSense code blocks, but that had been solved... everything seemed normal. Site worked in all modern browsers (I've made the mistake of not checking design changes in IE before...) and was evidently accessible from all over the world. Just a tragic shortage of AdSense impressions.
This morning, by chance, I clicked on a link to my site... and the page came up, but with no content (only the surrounding template). The software is designed so that no AdSense is shown in such a case (I'm a good citizen ;-). Reloaded the page and voila, everything came up as usual. What TF?
Turned out in the previous code I'd done a little referer checking but forgotten about the setting, and by an unfortunate combination of logic this led to the new code interpreting the setting as "do not display the content". Doh.
Yes, always a good reason to keep code complexity as low as possible since we all have such lapses of memory.
Every time I feel inclined to add another tweak I write it down and think about it for a bit and try to decide a cost/benefit/maint for it. About 30% of my whims get ditched or go at the end of the to-do list within about 24 hours!
Rgds
Damon
Fortunately I keep my AdSense eggs in different baskets (I used to work as an Easter Bunny ;-) so it was only a 40%~50% "loss". I'm just grateful the bots didn't get served the contentless pages, and no ads were displayed (could have been a nightmare if someone had noticed and complained to Google...)
a few months ago I decided I was going to rid my site of all the people hotlinking the files on it, problem was that most of the people hotlinking were using my download script (www.mysite.com/download.php?fileid=123) so instead of stopping people just hotlinking the files (gif, jpg etc) I decided that I would stop them from hotlinking the php files as well?
bandwidth over the next few days was way down so I was happy about that BUT my adsense earnings were also way down (and I mean way down) and I honestly was about to remove the php hotlink protection so that my earnings would go back to normal
anyway just before I was going to do it I decided to do a couple of searches to see where I was in google for certain keywords, as usualy was on the first page and I decided I would click the link and I freaked out when I clicked it.
turns out that by not allowing anyone to hotlink the php files it also meant that if anyone had clicked on a link to my site from anywhere else on the net apart from my site they were presented with a 302 forbiden message on every page they tried.
I had actualy banned every site on the net from linking to any of my pages, neadless to say as soon as the mild "heart attack" had passed I sorted out the .htaccess file to remove the php hotlink.
took me 3 or 4 days to realise what was happening, from now on I check check and then check some more.
regards
It turns out that the ad will not be displayed in IE, but works perfectly in Firefox.
It is not a very smart mistake to do the day before going on a one month trip.
Don't ask what it did cost me to find this out...;-/