Thursday, December 8, 2011

Adding Adsense code in Blogger
Posted on
  • Thursday, December 8, 2011
  • by
  • Unknown
  • , in
  • .
  • Whenever you try to add an adsense code before or after the post (or rather anywhere in blogger – except the sidebar where the ad works properly), in blogger, chances are that you may get a blank space instead of the ad you expected.

    This is because of the unique format of Blogger, which has its own tags in XML, which is quite different from HTML which adsense follows.

    adding-adsense-code-to-blogger In order to solve this problem, you have to parse the HTML text that the adsense control panel gives you, into XML format, which blogger supports.

    The basic condition to parse HTML tags and quotes into blogger-compatible format is to convert the following to the HTML characters. If you know how to parse those manually, then you are good to go, else use this parser to do it for you.

    Now that the code has been parsed for you, you can place the code anywhere in blogger. If you want the code to be with the post, look for the post tag in blogger, and place the code above or below it.

    < data:post.body />

    You can also place the blog anywhere in your blog, but remember – only three ads are supported at a time in Adsense!

    Subscribe to more tutorials

    Your privacy is taken very seriously.
    Share article: | Subscribe to RSS:

    0 Responses to “Adding Adsense code in Blogger”

    Post a Comment

    Modified Mash2 theme being used