• Resolved ralph88

    (@ralph88)


    Hi there,

    Just found this plugin and looks great! Considering purchasing the Premium plugin for user profiles/post creation on a current project.

    However in testing on this free version I found one UX issue which might need some thought.

    When uploading a file as an admin to a frontend form I noticed it was uploaded to the media library, which I can then manage and delete as necessary as an admin.

    However when uploading as a subscriber logged in user/guest the file doesn’t seem to appear in the media library possibly due to a pre_get_posts?. When an admin then views the entry under Forms, Entries, if they wanted to delete the users upload the intuitive thing is to click the cross that ACF gives you on hover. However this just disassociates the media item from the entry post but doesn’t delete the actual file. If you do that you can then no longer find the file upload, but it still exists in the filesystem which isn’t ideal.

    I can see that it is possible to delete the file if you click the edit button on the file and then delete it there but this is less intuitive.

    Hope this makes sense. Is there any other way to that I am missing to delete the File upload after you have disassociated the file from the af_entry post?

    Thanks

    Ralph

Viewing 1 replies (of 1 total)
  • Plugin Author fabianlindfors

    (@fabianlindfors)

    Hi!

    I see your problem and I’m afraid it’s more related to ACF than this plugin. The image field provided by ACF handles the image selection and also the little cross and deselection.
    I have looked into the ACF code but can’t find an obvious way to delete an image when it is deselected. The deselection seems to be done entirely through Javascript with no backend communication. The best way to solve this I think would be adding custom Javascript and listening to the click on the deselection cross. On a click you would then send an AJAX request to delete the deselected image.

    Hope this helps. Feel free to reach out if you have any questions about AF Pro!

Viewing 1 replies (of 1 total)
  • The topic ‘Deleting File After User uploads’ is closed to new replies.