Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • [email protected] 406 posts 2135 karma points MVP 7x c-trib
    Mar 31, 2017 @ 09:09
    jeffrey@umarketingsuite.com
    0

    Image Cropper datatype removing files from disk on "Save"

    Hi co-Umbraco-users,

    I've created an issue in the issue-tracker: http://issues.umbraco.org/issue/U4-9709. It's about the fact that when you save (and not publish) a node with a image cropper-datatype on it; the original file gets deleted from disk, although it's not published yet. By doing this the website breaks on the front-end because the published picture doesn't exist any longer. More details can be found in the issue itself.

    I'm wondering if some smart Umbracian can help me with figuring out a work-around for now, until Umbraco fixes the issue. Any thoughts?

    The only thing I can come up with is making an BeforeSave and AfterSave event on nodes and if that node contains an Image Cropper and the image has been changed there should be made a copy of the picture in the BeforeSave, then the original picture gets deleted by Umbraco, and in the AfterSave I restore the copied picture to the original.

    Any smarter solutions anyone can think of?

    Jeffrey

    p.s.: And of course upvote the issue if you think it makes sense :)

Please Sign in or register to post replies

Write your reply to:

Draft