Support

Account

Home Forums Add-ons Repeater Field Repeater images all the same size

Helping

Repeater images all the same size

  • Hello,

    I’ve taken over a WordPress site from another developer and I’m not entirely familiar with this plugin. So I might be missing something obvious.

    The original site was using ACF and WordPress 3.6 and ACF 4.2.1. After moving servers and upgrading to 3.8.1 and 4.3.4 respectively, something weird has happened to any images I’ve uploaded via the repeater plugin.

    Here’s a vardump example from the site running 3.8.1.:

    array(4) {
      ["image"]=>
      array(10) {
        ["id"]=>
        int(55)
        ["alt"]=>
        string(0) ""
        ["title"]=>
        string(12) "Lorem Ipsum"
        ["caption"]=>
        string(0) ""
        ["description"]=>
        string(0) ""
        ["mime_type"]=>
        string(10) "image/jpeg"
        ["url"]=>
        string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
        ["width"]=>
        int(2622)
        ["height"]=>
        int(1933)
        ["sizes"]=>
        array(24) {
          ["thumbnail"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["thumbnail-width"]=>
          int(150)
          ["thumbnail-height"]=>
          int(110)
          ["medium"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["medium-width"]=>
          int(300)
          ["medium-height"]=>
          int(221)
          ["large"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["large-width"]=>
          int(1024)
          ["large-height"]=>
          int(754)
          ["gallery_small"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["gallery_small-width"]=>
          int(395)
          ["gallery_small-height"]=>
          int(291)
          ["gallery_medium"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["gallery_medium-width"]=>
          int(562)
          ["gallery_medium-height"]=>
          int(415)
          ["gallery_large"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["gallery_large-width"]=>
          int(1148)
          ["gallery_large-height"]=>
          int(847)
          ["home_banner"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["home_banner-width"]=>
          int(1270)
          ["home_banner-height"]=>
          int(936)
          ["post-thumbnail"]=>
          string(76) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["post-thumbnail-width"]=>
          int(348)
          ["post-thumbnail-height"]=>
          int(257)
        }
      }
      ["description"]=>
      string(66) "Lorem Ipsum"
      ["size"]=>
      string(5) "Large"
      ["disclaimer"]=>
      string(1) "0"
    }

    No matter what the image size, it’s grabbing the same image file (the original full size attachment). Whereas the old site, running 3.6, would show the following:

    array(4) {
      ["image"]=>
      array(9) {
        ["id"]=>
        int(55)
        ["alt"]=>
        string(0) ""
        ["title"]=>
        string(12) "Lorem Ipsum"
        ["caption"]=>
        string(0) ""
        ["description"]=>
        string(0) ""
        ["url"]=>
        string(74) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
        ["width"]=>
        int(2622)
        ["height"]=>
        int(1933)
        ["sizes"]=>
        array(21) {
          ["thumbnail"]=>
          string(82) "[redacted]/wp-content/uploads/2013/08/FPO-image-150x150.jpg"
          ["thumbnail-width"]=>
          int(150)
          ["thumbnail-height"]=>
          int(150)
          ["medium"]=>
          string(82) "[redacted]/wp-content/uploads/2013/08/FPO-image-300x221.jpg"
          ["medium-width"]=>
          int(300)
          ["medium-height"]=>
          int(221)
          ["large"]=>
          string(83) "[redacted]/wp-content/uploads/2013/08/FPO-image-1024x754.jpg"
          ["large-width"]=>
          int(1024)
          ["large-height"]=>
          int(754)
          ["gallery_small"]=>
          string(82) "[redacted]/wp-content/uploads/2013/08/FPO-image-395x415.jpg"
          ["gallery_small-width"]=>
          int(395)
          ["gallery_small-height"]=>
          int(415)
          ["gallery_medium"]=>
          string(82) "[redacted]/wp-content/uploads/2013/08/FPO-image-819x415.jpg"
          ["gallery_medium-width"]=>
          int(819)
          ["gallery_medium-height"]=>
          int(415)
          ["gallery_large"]=>
          string(83) "[redacted]/wp-content/uploads/2013/08/FPO-image-1228x847.jpg"
          ["gallery_large-width"]=>
          int(1228)
          ["gallery_large-height"]=>
          int(847)
          ["post-thumbnail"]=>
          string(74) "[redacted]/wp-content/uploads/2013/08/FPO-image.jpg"
          ["post-thumbnail-width"]=>
          int(348)
          ["post-thumbnail-height"]=>
          int(257)
        }
      }
      ["description"]=>
      string(66) "Lorem Ipsum"
      ["size"]=>
      string(5) "Large"
      ["disclaimer"]=>
      string(1) "0"
    }

    Which is how I would expected it to perform. I’m not sure if this is because I switched hosts, or if it’s because of a plugin or WordPress update. Has anyone had this same issue?

  • Hi @pw3n

    it is most likely that the cropped image sizes have become corrupt.
    There are some WP plugins which will regenerate thumbnails (crop sizes).

    Run one of these tools to fix the issue.

    Thanks
    E

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Repeater images all the same size’ is closed to new replies.