• Resolved FrenchFries

    (@frenchfries)


    Hello.

    Been using this plugin for a little while and really happy with it.

    Recently we have enabled HTTPS for the site where this plugin is used, but the advert images are being delivered over HTTP and not HTTPS, so the Chrome browser warns about this and the green padlock in the address bar disappears, making the site look more insecure.

    The ad images are stored in wp-content/banners and I am using the %image% variable place-holder for the AdCode like this:
    <a href="/product/office-365/"><img src="%image%" /></a>

    The HTML generated on the page for the img src is always http://&#8230; even if the page is viewed over HTTPS.

    Is there a way to format the AdCode so that when the page is viewed over HTTP the advert image is retrieved over HTTP and when the page is viewed over HTTPS the advert image is also retrieved over HTTPS?

    I think I have already tried a relative link to the banner in the AdCode, like “/wp-content/banners/advert.jpg” instead of %image%, but the banner then failed to show up on the page.

    Thank-you,
    Paul

    https://ww.wp.xz.cn/plugins/adrotate/

Viewing 1 replies (of 1 total)
  • Plugin Author Arnan

    (@adegans)

    If your site is using HTTPS there is no reason for people to still use HTTP.
    Why not fix that issue and redirect all of your visitors to HTTPS 🙂
    This not only fixes your unsecured content issue, but it also looks more professional in general.

    This Article I wrote a while ago will help you achieve just that; https://ajdg.solutions/2015/03/30/switching-your-wordpress-site-to-ssl/

    Also, letting the browser figure out what protocol to use is never a good idea. If you use full urls (which include https://) you will fix the issue too. Using agnostic urls (using //) may work against you as well – Chrome and Safari are kinda dumb with them.

Viewing 1 replies (of 1 total)

The topic ‘Advert Image source HTTP and HTTPS’ is closed to new replies.