Give me 31 Days and I’ll Give You a Better Blog… Guaranteed

Check out 31 Days to Build a Better Blog

Give me 31 Days and I’ll Give You a Better Blog

Check it out

A Practical Podcast… to Help You Build a Better Blog

The ProBlogger Podcast

A Practical Podcast…

FREE Problogging tips delivered to your inbox  

AdSense add Channel Name to Code

Posted By Darren Rowse 25th of September 2006 Adsense 0 Comments

I was just making a new ad unit for one of my blogs and have noticed that when generating code for an ad unit in a channel that the channel code is no longer just a number but the name of the channel and the date you created it as well as a numerical code for the channel.

So the code now includes a line like this:

//2006-09-24: ProBlogger Main

I’m not sure why they’ve made this change. The previous numerical channel code is still in the code so they must have added it for some reason.

Unless there’s some pretty good reason for it I’m not sure I would want the code there as I know serious AdSense publishers do at times look at the source code in each others pages and I know some publishers use channel names that can be quite revealing about their AdSense strategy.

About Darren Rowse
Darren Rowse is the founder and editor of ProBlogger Blog Tips and Digital Photography School. Learn more about him here and connect with him on Twitter, Facebook, Google+ and LinkedIn.
  • Because that’s a comment, rather than actual code, you should have no problem with removing it.

  • But if you remove it, aren’t you technically violating the terms/policies set forth by Google that you cannot edit their code?

  • yea. i just found it awhile ago. maybe it is another way adsense team helping publishers to know what is the channel for the asd.

    Minor updates in AdSense code [CypherHackz.Net]

  • When you’r copying and pasting several Adsense scripts at a time, it’s easy to accidently copy the same channel twice. With the commented channel name, you can see that you copied the wrong channel in your script. Without it, all you see is a number and it’s easy to not notice you copied the same channel twice. I’ve done that a couple of times and didn’t realize it until later. By then, the stats are messed up.

  • It’s so you can trace back to the channel name from a given web page’s HTML. Before, unless you manually built a cross reference table between each channel id and channel name, you had no way easy way to know what channel(s) a page was using when looking at your web page’s HTML. You would literally have to generate ad code for every channel you had active, just to figure out the channel name the channel belonged to. This made the following tasks arduous and inconvenient:

    – tracking down an improperly assigned channel
    – renaming one or more channels or changing your usage of existing channels and subsequently identifying all pages that used the old channels for update purposes


  • steven

    thanx for all this good tips!