• I just discovered that a lot of my posts are showing the wrong images. I don’t know how long it has been that way. All posts since the beginning of 2019 seemed fine but for posts older than that the image galleries seem to be pointing to a previous post (usually either one or two posts earlier). Individual images are fine, it is just the galleries that are out of whack. At first I started fixing them manually but now I that I see it affects dozens of posts (maybe more, I stopped checking) I decided to see if this is a fixable issue.

    I have tried turning Jetpack Tiled Galleries on and off, allowing my theme to override (Virtue), turning Lightbox on and off, etc. None of that seems to change anything. It appears the galleries are just pointing to the wrong images for some reason.

    Thanks

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

Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    Sorry for the late reply. I hope you’ve resolved this by now. In case not, please confirm the issue is with the old style [gallery] shortcode. Are you saying the gallery shown in a post is showing images which belong to a different post? As you may know, the images shown in a gallery are saved as a list of image attachment IDs right in the shortcode. To be showing the wrong images, the attachment IDs within the database apparently had changed so that the ID list no longer corresponds to the correct images.

    Unless they are all off by a consistent amount (like add 10 to each ID to get the correct ID), there’s no easy fix. Somehow the database table had been altered a while back and there’s unlikely to be a way to recover at this point because a lot of new data had been added since then.

    Another possibility is your theme or a plugin has hijacked the shortcode operation in an inconsistent manner. Try switching to the twentytwenty theme and deactivating all plugins. If posts still show the wrong images, the above is true. If this fixes it, identify which module was the cause and take up the issue with its devs.

Viewing 1 replies (of 1 total)
  • The topic ‘Photo Gallery Showing Wrong Images’ is closed to new replies.