Need CSS ideas on loading second adsense ad first

(written by christopher)

Hi all,

My midpage adsense ad receives a higher ctr than my first (top) ad.

As per this suggestion from google, I would like to load my midpage ad first, so shows the highest bid on that unit.

First ad unit counts – AdSense Help

However, their example shows a way to set the ad into an absolute position on the page.

The way my page template works, the adsense ad is embedded in content. It appears after the fourth paragraph, not in a set/absolute location on the page.

Does you know a way I can put the ad code in a div and have it load prior to the others (as per their example) and then display the add in a manner that it will show between paragraphs, so I can do this:

paragraph-1
paragraph-2
paragraph-3
paragraph-4
<div> (show previously loaded ad here)</div>
paragraph-5
paragraph-6

Clear examples appreciated 🙂 🙂

It’s a shame google doesn’t just give us a way to easily set a priority order for ads!

Chris

This entry was posted in AdSense Placements and tagged , , . Bookmark the permalink.

4 Responses to Need CSS ideas on loading second adsense ad first

  1. admin says:
    You can only do this with css positioning.

    I wrote a mod for vBulletin once which does what you ask for.

    Maybe you get an idea out of it:
    A centered Banner below the navbar that is loaded AFTER
  2. christopher says:
    Thanks.

    I'm looking through yours too, but I did find the code below works.

    It gives me a bit of a pause only in that it means I'm loading an adsense ad in a div with "display:none" so I can show it later....

    I'm sure a real adsense employee would look at what I am doing and ok it as an adaptation of their suggestion, but I wonder if it would cause an issue with the adsense bot thinking I am doing something illicit.

    I may run it by adsense first to get their ok.

    Chris
     <html><body style=""> 
    <div id="loadad2" style="display:none">Insert</div> 
    <!-- top ad loads and appears here --!> 
    para 1<br> 
    para 2<br> 
    para 3<br> 
    para 4<br> 
    <span id="ad2"></span><br> 
    <script type="text/javascript"> 
    document.getElementById('ad2').innerHTML= document.getElementById('loadad2').innerHTML; 
    </script> 
    para 5<br> 
    para 6<br> 
    para 7<br> 
    </body> 
    </html>
  3. JamesColin says:
    Hmm.. I smell something wrong here, don't you think? I'm not sure but if you insert it in loadad2 and then after you copy the code in ad2, then there will be 2 instances of the adsense, no? So in fact the ad2 will still be the second instance..

    Try to display 3 adsense blocks with your setting and see if the third adsense block is still visible or not.

    I don't know if having display:none in loadad2 is enough to make adsense ignore it and think you have a total of 3 adsense block and not 4.

    But if it ignores loadad2 because of display:none, then why would it consider it being the first? It's either it is being ignored and then it is not considered as the first in html OR it is not being ignored and then adsense believes there are 4 adsense blocks, and so should not display ads in the last block (which would be the third visible one for you)
  4. christopher says:
    Interesting thought... I'll have some time to test this this afternoon and let you know :)

    I'm thinking it will load it once and display it somewhere else -

Leave a Reply

Your email address will not be published. Required fields are marked *

*