Hi there,
I am having a small issue with my background picture not showing. Maybe someone spots my mistake? The <img …> bit works and shows the picture, the <div…> does not show the picture as background, tho.
HTML:
<?php $image = $page->image('background.jpg'); ?>
<div class="header_img" style="background-image: <?= $image->url() ?>">
</div>
<img src="<?= $image->url() ?>">
CSS:
.header_img{
background-repeat: no-repeat;
background-position: center;
position: relative;
min-height: 400px;
}
It creates a 400px high empty box and then the picture from <img…>.
Any hints? Thanks!