• Resolved Jairo Ochoa

    (@jairoochoa)


    Hi,

    For some reason attachments are not deleted.
    We have created a new Custom Post Type and sometimes when deleting a item the images remain in Media folder.

    We have checked server php errors and they are empty so we do not known what we should look for.

    The site runs WP 4.9.7 and Autoremove Attachments 1.1.1

    Many thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Eusebiu Oprinoiu

    (@eusebiuoprinoiu)

    Hello, Jairo!

    Have you removed your posts from trash? The attachments are removed only when your posts are removed permanently from the database. A soft delete that places your posts in trash does not trigger the removal of your attachments.

    Also, only child attachments are removed. If your media attachments are uploaded from the Media > Add New, they have no parent, so they are not deleted, even if you use those attachments in posts / pages / custom posts. Can you, please, check the Uploaded To column of your Media Library and see if your attachments are actually attached to a post?

    Best regards,
    Eusebiu Oprinoiu

    Thread Starter Jairo Ochoa

    (@jairoochoa)

    Yes, post are removed from trash.

    There is a Custom Post Type vehicle and each one has a Feature Image and a Gallery created with Advanced Custom Fields.

    Great tip! I’ve check if the attachments have parent and there are some of them without.
    Probably the client uploads them from Media window instead from Post window.

    Many thanks.

    Plugin Author Eusebiu Oprinoiu

    (@eusebiuoprinoiu)

    You’re welcome! I’m glad I could help! ??

    Best regards,
    Eusebiu Oprinoiu

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘attachments are not deleted’ is closed to new replies.