image acf

Solutions on MaxInterview for image acf by the best coders in the world

showing results for - "image acf"
Adèle
20 Aug 2020
1<?php 
2$image = get_field('image');
3if( !empty( $image ) ): ?>
4    <img src="<?php echo esc_url($image['url']); ?>" alt="<?php echo esc_attr($image['alt']); ?>" />
5<?php endif; ?>
Luca
20 Sep 2019
1<?php
2$image = get_field('image');
3if( $image ):
4
5    // Image variables.
6    $url = $image['url'];
7    $title = $image['title'];
8    $alt = $image['alt'];
9    $caption = $image['caption'];
10
11    // Thumbnail size attributes.
12    $size = 'thumbnail';
13    $thumb = $image['sizes'][ $size ];
14    $width = $image['sizes'][ $size . '-width' ];
15    $height = $image['sizes'][ $size . '-height' ];
16
17    // Begin caption wrap.
18    if( $caption ): ?>
19        <div class="wp-caption">
20    <?php endif; ?>
21
22    <a href="<?php echo esc_url($url); ?>" title="<?php echo esc_attr($title); ?>">
23        <img src="<?php echo esc_url($thumb); ?>" alt="<?php echo esc_attr($alt); ?>" />
24    </a>
25
26    <?php 
27    // End caption wrap.
28    if( $caption ): ?>
29        <p class="wp-caption-text"><?php echo esc_html($caption); ?></p>
30        </div>
31    <?php endif; ?>
32<?php endif; ?>
Alex
03 Feb 2016
1<div class="about_photo">
2		<?php
3		$value =get_field('about_photo');
4		 echo "<img src='".$value."' width='200px' height='200px'>";
5		 ?>
6</div>
queries leading to this page
acf image return formatecho filed img acfthe field 28 27thumbnail 27 29wp screenshot image custom field pluginacf get image urlacf add imageacf field to select an imageadvanced custom fields how to pull imagesadvanced custom fields get imagedisplay image from custom fieldacf img srcimg acfacf render imageget image field acfwordpress get acf field imageacf add image to pageget custom field php wordpresswo get attachment image acfacf image fieldacf add image to the fieldimf acfacf image echo urlacf image arrayadvance custom field image fetch in function phpacf imagen urlacf image display settingswp php get custom fieldacf display image as a thumbnailacf display image 28url 29 sizeacf display image fieldacf photoshow to get image in acfget custom field image in wordpressget field imagephp the field image acfadvanced custom field return image pathacf get image srcacf imagesimage get in acfacf image docsget image in acfacf print imageacf default imageacf field imageshow acf image acf display imageget image url acf custom fields imageacf image urlacf add image to field descriptionget field image url acfacf iimageacf get imageacf webp images dimensions 1acf get image fieldimage acffields imageget image acfacf fields for imageget image using acfacf the field imagehow to add image using acfthe field acf imagecustom fields image id in wordpresswp 2bget custom field phptodisplay image in acfimage field in acfacf set imagewordpress get custom field phpacf image fielddacf field the imageacf imagewp php custom fieldsimage acf