• Resolved formicacraftuje

    (@formicacraftuje)


    I have seen couple of topics with exact same issue, but no solution.

    “Replace image” doesn’t replace the “preview thumbnail”, only the image that you see after clicking.

    Cache is cleared, deep refreshing, nothing helps.
    The source for the thumbnail is not replaced in the database of the gallery!

    Can you do something about it? Removing image and adding another is not the solution, because when you want to replace an image inside the gallery it messes all the tile order 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello @formicacraftuje

    Thanks you for reaching us !

    https://github.com/WPChill/gallery-photoblocks/issues/20 -> Thanks for reporting this bug, we managed to reproduce your problem and posted it on github.
    Thank you for understanding !

    Please let me know if you have some more quesitons !

    Have a nice day ! 🙂

    Warmly,
    Marian

    Thread Starter formicacraftuje

    (@formicacraftuje)

    Hi,
    I looked at the plugin code, and added couple of lines in function replaceImage in admin/js/photoblocks.grid.js. It helped.

    selection.map(function(attachment) {
              attachment = attachment.toJSON();
              $block.data("conf").image.url = attachment.url;
    /* added lines */
              $block.data("conf").image.id = attachment.id;
    	  if (attachment.sizes && attachment.sizes.thumbnail)
                  $block.data("conf").thumbnail = attachment.sizes.thumbnail.url;
              if (attachment.sizes && attachment.sizes.large)
                  $block.data("conf").large = attachment.sizes.large.url;
    /* end of added lines */
              $block.css({
                backgroundImage: "url('" + attachment.url + "')"
              })
            });

    Hello @formicacraftuje

    Thank you very much for your understanding!
    A solution will appear in connection with this problem, we do not know the exact date yet, but you have the topic here and you will be able to check the moment when it will be “solved”.
    Thank you again!

    Warmly,
    Marian

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Replace image doesn’t work’ is closed to new replies.