• Resolved Maxaud

    (@maxaud)


    I have an image I’m using in numerous places on my site and I have a media upload field custom field for posts. When I choose that image from the media picker and save everything works as it should. I can attach it to many many posts.

    However, when I click the “delete” button thinking it’s just removing the custom field for that post, it removes it from the entire system and breaks all my other posts that use that image.

    I feel that it should remove the image ID from JUST that post.

    https://www.ads-software.com/extend/plugins/custom-field-template/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Hiroaki Miyashita

    (@hiroaki-miyashita)

    Try the mediaRemove attribute.

    [file1]
    type = file
    mediaPicker = true
    mediaRemove = true
    Thread Starter Maxaud

    (@maxaud)

    Apologies, I should have looked more in depth in to the documentation.

    I’d like to suggest making this the default setting if the media picker is also added to the custom field.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Deleting image added through media picker deletes from WordPress database’ is closed to new replies.