title: How to display acf image from image array
body: <p>I have this query - </p>
  
  <pre><code>&lt;?php if (has_term( 'channel', 'listing_area' )) { ?&gt;
  
  
  &lt;?php
          $posts = get_posts(array(
  'numberposts'   =&gt; 3,
  'post_type'     =&gt; 'adverts',
  'order_by' =&gt; 'title',
  'order' =&gt; 'random',
  'meta_query'    =&gt; array(
      'relation'      =&gt; 'AND',
      array(
          'key'       =&gt; 'associate_adverts',
          'value'     =&gt; '1822',
          'compare'   =&gt; 'LIKE',
      )
  ),
   ));
  
      ?&gt;
  
  
    &lt;?php //if it's returning the object
  
       foreach($posts as $advert){
  
         $img = get_field("advert", $advert-&gt;id);?&gt;
  
   &lt;img src="&lt;?php echo $img["url"]; ?&gt;"/&gt;
  
    &lt;?php }?&gt;
  </code></pre>
  
  
  
  <p>I need to show an image called from an advanced custom field called 'advert' which is set to use the image array option where I'm calling the post title.</p>
  
  <p>How can I do this? Thanks.</p>