Answers for "advanced custom fields pro gallery"

PHP
3

gallery advanced custom fields

<?php 
$images = get_field('gallery');
$size = 'full'; // (thumbnail, medium, large, full or custom size)
if( $images ): ?>
    <ul>
        <?php foreach( $images as $image_id ): ?>
            <li>
                <?php echo wp_get_attachment_image( $image_id, $size ); ?>
            </li>
        <?php endforeach; ?>
    </ul>
<?php endif; ?>
Posted by: Guest on March-06-2020

Code answers related to "advanced custom fields pro gallery"

Browse Popular Code Answers by Language