Copied to clipboard

Flag this post as spam?

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


  • Paul de Quant 209 posts 958 karma points
    Jul 14, 2017 @ 16:26
    Paul de Quant
    0

    Removing orphaned images

    Hello,

    Does anyone have any code, that deletes orphaned images from the Umbraco CMS. I need to do a bit of house keeping and it would be good to have this option.

    Many thanks

    Paul

  • Nicholas Westby 1624 posts 5296 karma points c-trib
    Jul 14, 2017 @ 16:38
    Nicholas Westby
    0

    It won't be fully comprehensive (e.g., if a link to an image is hardcoded), but the Nexu package may work for this: https://our.umbraco.org/projects/backoffice-extensions/nexu/

  • Paul de Quant 209 posts 958 karma points
    Jul 17, 2017 @ 07:19
    Paul de Quant
    0

    Hi Nicholas,

    Thanks for this, although I need something that can do it in bulk. Something to loop through all files in the media folder and delete the files that are no longer in use.

    Thanks

    Paul

Please Sign in or register to post replies

Write your reply to:

Draft