Explanation of how to place Adsense ads inside the Blogger article

The introduction

Google Adsense, or what is known as Google adsense, which everyone seeks to obtain an activated account with Google Adsense, and there are many ways to profit from the Google Adsense company. Some seek to create a YouTube channel, others seek profit by creating an application on the Google Play Store or on the Play Store, others create a website and display Google Adsense ads, and some people create a blog on free platforms such as Blogger. Blogger allows you to create a blog for free and has many advantages, and allows you to install a template on it Whether it is free or paid, we have previously explained how to create a Blogger blog, how to create a Google Adsense account, how to activate it, how to link a Blogger blog to Google Adsense, how to configure the blog, and how to accept it with Google Adsense. Or the paid SEO Plus template. We will explain all of that in this article
Explanation of how to place Adsense ads inside the Blogger article


First, you should know that there are three places to place ads within the article, the beginning of the article, the middle of the article, and the bottom of the article

 But first, let's explain how to get the ads, then let's explain how to place the advertisement separately

 How to get adsense ads code


 First, we go to Google Adsense, click on the menu, select Ads, and then Overview

 Then you will find three options

 By location, by ad unit, and general settings

 We choose according to the ad unit, then click on the advertisement option within the article, then we write the name of the ad unit, for example, we call it the ad at the beginning of the article, then we press Done, and we copy the code shown and save it in the txt file or in the notepad if you are using a mobile phone

 Then we repeat this process three times with three in-article ad units

 And we call them as follows

 Announcement of the first article

 And an advertisement in the middle of the article

 And an announcement at the end of the article

 Then to enter the second part of our topic today


 How to place ads inside HTML code in Blogger


 After we have saved the three codes for three ads inside the article

 We log into the blogger platform

 Then we go to appearance

 Then we click on the mark next to Customize and then choose Edit HTML

 The entire blog code will appear in front of you

 We click on search and search for the following sentence
<data: post.body/>

Then how to place ads

 Announcement of the first article

 We paste the Adsense ad code that we called the advertisement at the beginning of the article

 We paste above the code

 Ad at the bottom of the article

 You put the Adsense ad code that we named at the bottom of the article. We paste it below the code

 As for the

 Ad in the middle of the article

 It is simple, God willing

 We delete the code that we searched for and put the following code in its place

<div expr:id='"aim1" + data:post.id'>
</div>
<div  style="clear:both; margin:10px 0">
 
Put the Adsense code to the right of the article here

</div>
<div  expr:id='"aim2" + data:post.id'>
<data:post.body/>
</div>
<script  type="text/javascript">
var  obj0=document.getElementById("aim1<data:post.id/>");
var  obj1=document.getElementById("aim2<data:post.id/>");
var  s=obj1.innerHTML;
var r=s.search(/\x3C!-- adsense --\x3E/igm);
if(r>0)  {obj0.innerHTML=s.substr(0,r);obj1.innerHTML=s.substr(r+16);}
</script>
And we put the Adsense ad code in the middle of the article inside instead of the word written in Arabic

 Here we come to the end of the article

 Peace, mercy and blessings of God

 my regards


Hossam khaled
By : Hossam khaled
Human doctor, writer of articles in medicine and technology
Comments