Hello! I have two field group (1 and 2 on image). 1 – Homepage, 2 – Post type
In second field i have content, which i can get from by this command:
esc_html( $featured_post->post_title )
but I can’t get image (neither in array, url, id form) from this field group.
I am noob in wordpress and especialy in ACF, although have programming background.
Please, if anyone can help, I would be very appreciate it.
Please can you share your code? Is this on a single post or within a loop?
Assuming it’s set to array, your code should look like:
<?php
$image = get_field('review_icon');
if( !empty( $image ) ): ?>
<img src="<?php echo esc_url($image['url']); ?>" alt="<?php echo esc_attr($image['alt']); ?>" />
<?php endif; ?>