Support » Fixing WordPress » images on specific dates not showing in media gallery

  • Hello

    I have a weird issue where 95% of images from November and December 2016 are not showing in the media gallery. (we are a news site and have thousands of images)

    When I check the on the server they are all there. Image permissions are 644. Folder permissions are 755.

    If I view a post from this date range, the images show in the article, but feature image is not there. when I search for any of the images either feature on in the content they do not show in media gallery but again are all on the server?

    I am not sure when this issue could of happened as have only really noticed it now. The same issue is present on my duplicate development site too that is about 6 months old.

    On my dev site I have disabled all plugins and and used a default wordpress theme to troubleshoot but still the same.

    Any help/suggestions will be greatly appreciated.

    Thanks

    Ryan

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

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator bcworkz

    (@bcworkz)

    The featured image is supposed to be a header background? The header background URL is empty, as you are likely aware. There’s apparently something wrong with the attachment posts related to the image. Without the data from the attachment post, it doesn’t matter if the file exists or not. How many articles are involved? One solution is to re-upload featured images for each article, a bit impractical if many articles are involved.

    See if the attachment post even exists. If it does, maybe it can be corrected by an appropriate SQL query. Use the phpMyAdmin app (usually accessed through the hosting account). Search for “attachment” post_type with the post_parent field value equal to the article’s post ID. If found, compare with a valid, functioning attachment post. There is also related data in postmeta that needs to be correct for it to all work right.

    Thread Starter pappaclart

    (@pappaclart)

    Hey Thanks for the reply

    I am not sure how many articles though there would be 2 months worth so probably a couple of hundred.

    When I look in media gallery for October or November 2016 Ihave 7 ages of images, but normally I have 130-150 pages of images for September and December.

    We did migrate to a new theme in May this year. The new theme bundled a migration plugin, could that potentially be the issue?

    Thanks for your help.

    Moderator bcworkz

    (@bcworkz)

    That’s likely. There are too many articles to manually correct. And the original DB data would now be missing all new content since May, so re-doing the migration through a different method is not an option either. Are you even able to access the original DB data? In theory the missing attachment posts could be exported/imported as new attachment posts. There are a lot of details to get perfectly correct for this to be successful. This is approaches forensic data recovery sort of stuff, though very pedestrian for that sort of expert.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘images on specific dates not showing in media gallery’ is closed to new replies.