Support

Account

Home Forums General Issues images urls converting to https Reply To: images urls converting to https

  • With WP Engine and a similar issue.

    We have the following code

    <?php $image = wp_get_attachment_image_src(get_field('home_hero_image'), 'home-slide'); ?>
    <div class="home-top" style="background-image:url('<?php echo $image[0]; ?>');">

    This image source always outputs HTTP. So when we access page with HTTPS it warns us this is unsecure content. I’ll see if I can add another way, but I thought using $image[0] was best practice.

    Elliot