Support » Plugin: AdSense Plugin WP QUADS » adsbygoogle.push() error: No slot size for availableWidth=0 | Blank ads solution

  • ResolvedPlugin Author Rene Hermenau

    (@renehermi)


    Sometimes your AdSense ads are not shown and you see a blank space. This mainly happens when there is not enough space for rendering the AdSense ads.

    Sometimes there is enough space but AdSense is not able to detect the available space of the parent element containing the AdSense code because of theme related specifics.

    In the javascript error console you will see an error notice like:

    adsbygoogle.push() error: No slot size for availableWidth=0

    To fix this you can try the following:

    Use the Align: Center option in WP QUADS for the AdSense position alignment

    If this does not work:

    Create a div container around the AdSense code and give it a fixed size corresponding to the desired AdSense format.

    If you want to create an rectangular AdSense ad with size 250×250 use the code:

    <div style="min-width:250px;min-height:250px;">AdSense code here</div>

    https://wordpress.org/plugins/quick-adsense-reloaded/

Viewing 9 replies - 1 through 9 (of 9 total)
  • This is specifically true with Google’s responsive units. Width and Height must be specified. I like max-height and max-width as those responsive units can throw in some larger ads an “min” settings

    Amar

    (@amreshkramar)

    Some major issue, this plugin has

    I am using responsive ads

    & using the code below to create a rectangle container

    <div style=”max-width:350px;max-height:294px;”>
    AdSense code here
    </div>

    Issue One:-

    >> Ads not showing when the container is aligned left
    >> Ads showing only when the container is floated center or right
    However, the ads box appear on the left side of post page

    To solve this I use

    <div align=”center”
    <div style=”max-width:350px;max-height:294px;”>
    AdSense code here
    </div>
    </div>

    This is some kind of bug

    Issue Two :

    When Ads container box appear left side than margin 10px is applied correctly all the sides

    However, by using div align when I forced ads container to appear center of the post page than the content after the container box is stick to the box. 10px margin does not work at the bottom side of the container, it works only on the top side.

    Please help on this

    Do you suggest me using this code

    <p>
    <div align=”center”
    <div style=”max-width:350px;max-height:294px;”>
    AdSense code here
    </div>
    </div>
    </p>

    Amar

    (@amreshkramar)

    sorry

    I mean this way

    <div align=”center”
    <div style=”max-width:350px;max-height:294px;”>
    <p>
    AdSense code here
    </p>
    </div>
    </div>

    Amar

    (@amreshkramar)

    or will you make some improvement in the plugin?

    Plugin Author Rene Hermenau

    (@renehermi)

    Hi,

    the code you were posting should be fine. If i find some time i consider to integrate better responsive adsense support in a future version.

    I get the error as well, but still I can see the ads. I am wondering why is that.

    Plugin Author Rene Hermenau

    (@renehermi)

    Just a note: If you are facing this error and you are not able to fix it with the mentioned css customization you can try out WP QUADS PRO. It allows you to specify custom ad sizes for responsive ads which resolves this issue.

    Hi, I’ve tried all of the above steps and more, but none of my ads are displaying. Ad check shows the correct placements in green, and I have no errors in console. I tried testing text instead of adsense code and it displays fine. But no ads when using adsense code. Any way to submit a support request to help figure it out?

    • This reply was modified 2 years, 5 months ago by HRK123.
    Plugin Author Rene Hermenau

    (@renehermi)

    This will help you: https://wpquads.com/docs/adsense-ads-are-not-showing/

    If you still have issues let me know your website url

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘adsbygoogle.push() error: No slot size for availableWidth=0 | Blank ads solution’ is closed to new replies.