• Hi. I am trying to make both the width and height of my header image responsive. I have made the width responsive by using 100% and this works, yet when I also change height to a ‘%’ instead of a ‘px’ then the header breaks and is not displayed? Please can you help? The code I am using is below:

    <div class=”chi_display_header” style=”height:150px; width:100%; margin: 0 10%; background-image:url(‘[image_url]’);”></div>

    https://wordpress.org/plugins/custom-header-images/

Viewing 1 replies (of 1 total)
  • It would probably be best to remove the inline styles and apply it directly to the class through breakpoints (I’m sure you only want the scaling when it gets to a certain size). Have you tried removing height altogether or change to auto (it should be auto anyway to be proportionate).

Viewing 1 replies (of 1 total)
  • The topic ‘Responsive element not working’ is closed to new replies.