• Resolved cloe89

    (@cloe89)


    hi! i have a problem with this theme. http://viaggiosocial.it.
    the responsive ad in the header (added with shortcodes) doesn’t display in desktop (but in mobile it does).

    moreover, i can’t add a plavid code, neither with shortcodes or quick adsense. can you help? 🙁

Viewing 9 replies - 1 through 9 (of 9 total)
  • Theme Author Richie KS

    (@rkcorp)

    if it show, then the ad is working.
    however you’re asking for something that is not theme related, must be the adsense code issue.

    try clear cache maybe..

    Thread Starter cloe89

    (@cloe89)

    i’ve tried. But the ad doesn’t show in desktop.
    the ad code works correctly in any other theme.

    Theme Author Richie KS

    (@rkcorp)

    no idea.
    if resize the browser to 700px below and refresh, the ad will show.
    try add this to theme option->custom css

    #topbanner {width:728px;height:90px;}

    Thread Starter cloe89

    (@cloe89)

    if i add that code, the ad lose the responsiveness..

    Theme Author Richie KS

    (@rkcorp)

    but if you add the css and refresh the site, did the ad code appearead?
    could you at least try first?

    i want to know if adsense code need to check the div width for responsive..the current #topbanner did not have width set in css..

    so please try the css code first and let me know..

    Thread Starter cloe89

    (@cloe89)

    hi, obviously i’ve tried. if i put the code, the ad shows but it loses responsiveness.

    Theme Author Richie KS

    (@rkcorp)

    i see, so the google responsive code ‘needed’ the div width to work. try add this to theme option->custom css

    /*desktop*/
    @media only screen and (min-width:800px)and (max-width:3000px){
    #topbanner {width:728px;height:90px;}
    }
    /*ipad*/
    @media only screen and (min-width:400px)and (max-width:780px){
    #topbanner {width:468px;height:60px;}
    }
    /*iphone*/
    @media only screen and (min-width:240px)and (max-width:390px){
    #topbanner {width:300px;height:250px;}
    }
    Thread Starter cloe89

    (@cloe89)

    it works, but it’s not perfect with all the devices (see http://www.responsinator.com/?url=www.viaggiosocial.it%2F). can we improve the code?

    Theme Author Richie KS

    (@rkcorp)

    you will need to experiement and tweak the min-width, max-width and the suitable ad width and height to show in particular dimension.

    maybe height: auto; on the last iphone code.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘problem with responsive ads in header’ is closed to new replies.