Support » Plugin: Advanced Custom Fields » ACF Gallery not linking to image sizes after WordPress update from 4.x to 5.21

  • Resolved hunts57


    I’m absolutely perplexed. The custom field and php in the template have been running for years without incident. As you can see below I have two image sizes to call, the ‘thumbnail’ and the custom size ‘works’. Now however it just calls the original image in most cases . . . . the thumbnails should be 300×300 if you check in the link the first 8 images are not 300×300 in fact they are the full sized image and to add to the strange the next 16 images are correct!
    – I’ve checked to see that the all the correct images are on the server and they are.
    – The only error I get in the console is: Unchecked runtime.lastError: The message port closed before a response was received.
    – I did get this error on the page right after the update, but when I increased the memory for WordPress it went away: Fatal error: Maximum execution time of 30 seconds exceeded in /home/content/73/10555273/html/wp-includes/class-wp-image-editor-imagick.php on line 155

    $images = get_field('galleria_principale');
    if( $images ): ?>
        <div id="artists-images" class="linksy">
            <ul class="small-block-grid-1 medium-block-grid-3 large-block-grid-4">
                <?php foreach( $images as $image ): ?>
                        <a  class="fancybox"  rel="gallery01" href="<?php echo $image['sizes']['works']; ?>"  data-title-id="<?php echo $image['alt']; ?>"  title="<?php echo $image['title']; ?>">  <img src="<?php echo $image['sizes']['thumbnail']; ?>" alt="" /></a>
                        <div id="<?php echo $image['alt']; ?>" class="hidden">
    						<h4><?php echo $image['title']; ?></h4>
    						<p><?php echo $image['description']; ?></p>
                <?php endforeach; ?>
    <?php endif; ?>

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Figured it out. My thumbnails were 300×300 and so were the thumbnails in WooComerce. I just used the WooCommerce thumbnails and everything works again.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.