Home Forums Front-end Issues WordPress 4.4 responsive images Reply To: WordPress 4.4 responsive images

  • Hi,

    This looks like it is exactly what I’m trying to do but I can’t seem to get it to work. I’m not a very experienced code writer. Sorry for that 🙂

    I have added timstl’s function-code to my function.php and then in my template added:

    <div class="wrapper">
    	<div class="wrapper2">
    	<img class="bilder2" src="<?php echo wp_get_attachment_image(get_sub_field('hero_image'), 'full'); ?>					    						</div>

    Also I have changed the field to return image ID. But it doesn’t seem to work for me.
    Anyone who could point me in the right direction?