[Support request] Header ad not displayed

Home Forums Support Header ad not displayed

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1115845
    Keshav

    Hi,

    I have added google ad at header through widget. But ad is not showing on website.

    Website URL is: wikiwiki.in

    Please help.

    Thanks

    #1115861
    David
    Staff
    Customer Support

    Hi there,

    i am seeing this error in the developers console:

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

    This happens when a Respsonsive Ad is loaded into a container that has no set width.

    You can test to see if this is the issue by adding this CSS:

    .header-widget .custom-html-widget .adsbygoogle {
        min-width: 640px;
    }
    #1115872
    Keshav

    Thanks for replying.

    Code is working on desktop but not working on mobile.

    #1115873
    David
    Staff
    Customer Support

    Thats because you have the Mobile Header enabled in Customizer > Layout > Header.
    This removes the Header Widget. You would need to disable this for it to work.

    You would also need to adjust CSS for mobile and desktop:

    /* Mobile */
    @media(min-width: 768px) {
        .header-widget .custom-html-widget .adsbygoogle {
            width: auto;
            max-width: 640px;
        }
    }
    
    /* Desktop */
    @media(min-width: 769px) {
        .header-widget .custom-html-widget .adsbygoogle {
            min-width: 640px;
        }
    }

    Adjust the Width properties accordingly.

    #1115914
    Keshav

    Thank you so much.. Issue resolved.

    #1116589
    David
    Staff
    Customer Support
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.