Support

Account

Home Forums ACF PRO Error display field image Reply To: Error display field image

  • By default images are returned as an array.

    You need to either change this to URL, or else you can pull the details from the array to get the URL, eg:

    
    <?php
    $image = get_field('ac_imagem_destaque');
    if( $image): 
       $alt = $image['alt'];		
       $thumb = $image['url'];
       $width = $image['width'];
       $height = $image['height'];
       ?>
    
       <img src="<?php echo $thumb; ?>" alt="<?php echo $alt; ?>" width="<?php echo $width; ?>" height="<?php echo $height; ?>" class="thumb_285_350" />
    										
    <?php endif; ?>
    

    You can read more here – http://www.advancedcustomfields.com/resources/image/