Welcome to WebmasterWorld Guest from 3.80.4.76

Forum Moderators: martinibuster

Blank ad space and collapsing

     
9:51 pm on Aug 20, 2019 (gmt 0)

Senior Member

WebmasterWorld Senior Member Top Contributors Of The Month

joined:Nov 13, 2016
posts:1194
votes: 284


Hi,

The other day I was answering @gatormark that, my "blank" ad spaces were correctly being collapsed by Adsense.

I thought it might deserve a discussion on its own, especially since, in a near future (or may be even right now), this is what Adsense is going to do for all slots: [webmasterworld.com...] (among other things).

So, from "my" observations on "my" site (may be it's different elsewhere) :

- Ad slots above the fold, are never collapsed
If this is the expected behavior, I guess that this is to prevent "jumps" of the page layout, I don't know which word you are using in English. I mean, when elements of a page, keeps moving up and down as other elements are getting their final size. (good practice is to set the size of elements or/and placeholders)
Before being collapsed, ad slots are getting their desired size, then the height is turned into 0px if empty.
So, if even a tiny bit of an ad slot is visible above the fold, it won't be collapsed.

- If you control the size of the ad slot using CSS, then the ad slot will not be collapsed.

- Finally, if you want to detect, in javascript, if a slot is collapsed, you can check its height, using a timer function for example, but, the best remains to use the the ResizeObserver interface: [developer.mozilla.org...] . However, it's actually supported only by Chrome and Opera, (and the next update of Firefox)
8:32 am on Aug 30, 2019 (gmt 0)

New User

joined:Aug 30, 2019
posts:30
votes: 6


Hello Dimitri-

I think you are right. Since a while, adsense no longer collapses blank ads above the fold. This sucks, especially since Adsense discontinued backup ads!

There must be a way, beside using AdManager.
 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members