AdSense

A dSense is an advertisement serving program run by Google. Website owners can enroll in this program to enable text, image, and video advertisements on their websites. These ads are administered by Google and generate revenue. No claim is made as to the accuracy of information on this page. Before joining AdSense or making changes to your code be sure to check out the AdSense help section.

Contains excerpt from Wikipedia used under the GNU Free Documentation License.

 

Tip 1: Section Targeting

Google AdSense decides what ads to serve on your site, based on its analysis of your page content. Sometimes that analysis is very good but occasionally particular words or phrases, or a page that doesn't have enough content for the algorithm to bite into, will give you strange or inappropriate results.

For example I created a product spotlight section on my site. Google's analysis was that the page was about electrical lighting and so I got ads served that relate to that. My art gallery page was attracting various links of an adult nature.

In fact, with the relatively small amount of text on this page, it is likely that the words in the paragraph above adult, nature, spotlight, electrical and so on would result in some unexpected ads if I hadn't surrounded those paragraphs with the special ignore tagging described below.

What to do? Well, the first thing I find myself doing is self editing as I write - become more aware of your word choices on pages you intend to add AdSense to. The other thing we can do is take advantage of some tags that Google has created that will tell the AdSense bot to ignore or emphasize certain content.

Ignore Content

<!-- google_ad_section_start(weight=ignore) -->

    This would be used to surround the content you want to ignore.

<!-- google_ad_section_end -->

Emphasize Content

<!-- google_ad_section_start -->

    This would be used to surround the content you want to emphasize.

<!-- google_ad_section_end -->

In my case I also had to surround the site menu links with ignore tags as I found that they influenced the ads on pages which didn't have a lot of other text. Here is the section targeting answer page on Google. You may also find the Adsense Groups a useful place to ask specific questions.

 

Tip 2: Speeding Up Page Loads

The first thing you should do is check out the AdSense Resource page. Here you'll find some Google optimization tips as well as links to the AdSense groups where you can browse old questions and ask your own.

Position Your Code

One thing you should consider is placing your AdSense code just before the closing BODY tag. This allows the bulk of the page to load normally. Otherwise, if their is a delay retrieving the js file from Google the page may hang for a while until it downloads the file, or it times out.

//Your AdSense Code here

</body>

</html>

Assign Div Size

It appears that enclosing the code in a div and assigning width to it might speed up the appearance of the page rendering a little. I don't have proof of this but in my unofficial and unscientific eyeballing of the page while it loads, with and without this, it seems to load marginally faster. You decide ...

For example my text links at the top are enclosed in a div ...

<div class="google_ad_top">

//my adsense code

</div>

... and in my style sheet I set width and height.

 

 .google_ad_top{        
margin-bottom: 10px;
text-align: center;
display: block;
margin-right: auto;
margin-left: auto;
width: 730px;
height: 14px;
}

 

Need a new web host? Click the HostGator banner and use
coupon code STORMHOST25 for 25% off hosting or STORMBOSS24 for $24.94 of a reseller package.


Copyright Humberto Abreu 2004-2012 - All Rights Reserved


footer image
Personal FilesPersonal FilesPersonal Files