Skip to main content

Embedding Google Adsense in Blogger Post

Embedding Google Adsense in Blogger Post

One thing that is important is the positioning of Adsense ads. By embedding Google Adsense in Blogger posts you have some control over positioning that is close to and/or directly above the post itself.

If you have a Google Adsense account, as you know, you can make a bit of dosh (money) by putting up Adsense on your Blogger website. The modern version of Adsense widget is excellent. It is very easy and Google matches the colors for you etc. The only criticism that some people might have is that the ads are placed in widgets (blocks of code around the actually post) rather than actually in the post. It is debatable whether this is important but some people think it is, hence this post. You can see the text adsense in this post and throughout the blog. I also have some adverts from an advertising agency. Why? Because with Adsense you can have only 3 pieces of Adsense on the page at one time. Using another form of adverts allows more advertising on the page.

The only places you can place the embedded code is at the top and/or bottom of the post. The top position as you can see from this post is just above the title, a place that cannot be missed by visitors. In order to achieve that two thing need to be carried out:
  1. (This is not in controvention of Adsense or Google rules) change the code. This means changing certain elements of the code and;
  2. Placing it in the right place in the template.
Both steps are relatively easy.

Embedding Google Adsense in Blogger Post - Changing the code:

Here is a piece of Adsense code (you will need your own, with your own account number in it so don't use this):

<div align="center">
<script type="text/javascript"><!--
google_ad_client = "pub-9258716987841758";
/* 468x60, created 6/3/08 */
google_ad_slot = "2680821816";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</div>

We need to change these elements:
  • <
  • >
  • "
This chart shows the substituted symbols:

What you want to showWhat you replace it with
"&quot;
&&amp;
<&lt;
>&gt;

Once you have done that you get what likes like a jumble of code like this:

&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;pub-9258716987841758&quot;;
google_ad_host = &quot;pub-1599271086004685&quot;;
/* 468x60, created 10/1/08 */
google_ad_slot = &quot;9782827967&quot;;
google_ad_width = 468;
google_ad_height = 60;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;

Embedding Google Adsense in Blogger Post - Placing code in correct postion

Next go to Edit Html page of your blog. Save the template (download it) and open the widgets by clicking on Expand Widget Templates. Using the Ctrl F search facility paste into the search box this code: <data:post.body/>

The code should come up painted in green. Paste the modified code just below this line of code. You might need to put in a line break or two to lower the Adsense. This will place the Adsense at the base of the post. To place it at the top just above the header, for example, search for this code using Ctrl F: post-title entry-title. Then paste in the modified Adsense code just above the line of searched for code (the full line might look like this: <h3 class='post-title entry-title'>). You might put in a line break (<br/>) inbetween the post title code and the Adsense to separate it. Then review the changes.

Always review the template before saving. This works well and I have just checked it out on a new Minima template and it worked fine. Another point. You won't need to manually add Adsense as it will automatically come up in these places each time you make a post. If you put up two pieces of code this way you can use one more Adsense widget if you like, making three. Now the last point. If you request that Blogger show more than two posts on the home page at one time the third post will have gaps where the Adsense was as only three pieces of Adsense is allowed on the page at one time, as mentioned. If the Adsense is slim as is the case for me this doesn't matter.
Embedding Google Adsense in Blogger Post is pretty easy but go slow and check!

Comments

thanks for the pointers. i am about to set up adsense on my blog, as well. this will definitely help! :)
Michael Broad said…
Hi, pleased to help a bit and good luck with it. Go slow and sure and check before saving.
Latif Romadhon said…
I think Adsense on the blog post is high CTR. but that is make a visitor avoid for click more on a blog or website.

Popular posts from this blog

Cat Ear Mites

Brown gunge. Yes, I know this is a ferret! It does show the build up of dark brown to black ear wax caused by the presence of the cat ear mites in the outer ear canal. This parasite is not restricted to the domestic cat, which makes this photo valid and a useful illustration (I was unable to find a suitable photo of a cat with the condition). Photo Stacy Lynn Baum under a creative commons license. Ear mites (minute crab like creatures) are one of the causes of inflammation of the outer ear canal (scientific term for this inflammation is Otitis externa ). The outer ear canal is the tube that runs from outside to the ear drum (the pathway for the reception of sound), which can be seen when looking at the ear. Otitis externa affects humans and often swimmers as it is called "swimmer's ear" in humans. This YouTube video show ear mites under a microscope. They are not actually in the ear in this video. There are many possible causes of Otitis externa in c

Feline Mange

I'll write about three types of feline mange (a) feline scabies or head mange (b) demodectic mange and (c) sarcoptic mange. The source material is from Cat Owner's Home Veterinary Handbook - the best on the market . Generalised feline mange? Puerto Rico - Photo by Gotham City Lost And Found Feline Scabies - head mange Head mange or feline scabies, is a fairly rare condition in cats, which is caused by the Notoedres mite (head mite) that only reproduces on cats. The female mites burrow a few millimeters (that is a lot) into the skin around the head, and neck to lay eggs, which hatch and lay their own eggs. Their presence and activities causes intense itching that in turn causes the cat to scratch. The scratching will obviously be noticed and it will cause the skin to become red, scratched and worse infected. Symptoms: hair loss and scabs, thick wrinkled skin and grey/yellow crusts form plus the symptoms of scratching. Feline mange (head mange) is contagious and tr

Cat Anatomy

Cat Anatomy - Photo by Curious Expeditions . The picture above was taken at Wax Anatomical Models at La Specola in Florence, Italy. The photograph is published under a creative commons license kindly granted by the photographer. I am sorry if it is a bit gruesome. It is pretty well all I could find as an illustration that was licensed for publication. Cat Anatomy is a very wide ranging subject. The anatomy of a cat is very similar to human anatomy. If you were writing a biology book for students of biology you would go through every part of the a cat's anatomy in some detail. It would be similar to writing a book about the human anatomy. It would be a thick book and pretty boring for your average internet surfer. So, how do you limit such a big subject and make this post meaningful? The answer I think lies in doing two things: Having a quick general look at cat anatomy - an overview and; Focusing on the areas of cat anatomy that are particular to the cat and of parti