Copied to clipboard

Flag this post as spam?

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


  • Vinoj Kumar 11 posts 31 karma points
    Oct 25, 2016 @ 06:50
    Vinoj Kumar
    0

    Delete unused images from Media Folder

    Hi,

    Can any one please help me on deleting the unused images from the Media folder? Please help me out on this as I have a lot of images which is unused.

  • Alex Skrypnyk 6162 posts 24132 karma points MVP 8x admin c-trib
    Oct 25, 2016 @ 16:14
    Alex Skrypnyk
    104

    Hi Vinoj,

    This is exactly what this package can do, please look at - https://our.umbraco.org/projects/backoffice-extensions/falm-housekeeping/

    Thanks,

    Alex

  • Alex Skrypnyk 6162 posts 24132 karma points MVP 8x admin c-trib
    Nov 07, 2016 @ 11:27
    Alex Skrypnyk
    0

    Hi Vinoj

    Did you find solution?

    Can you share with our community?

    Thanks,

    Alex

  • Comment author was deleted

    Jan 10, 2018 @ 13:53

    Hi Alex, I have the same issue of Vinoj and I have installed the package named up. In the page it says "ATTENTION! To view the new FALM section you must enable it for all users that can use this tool."

    Of course.... I don't have a clue about how to do that and I can't see the section, shame on me, please share your answer with me

    Thank you, Alessandro

  • Alex Skrypnyk 6162 posts 24132 karma points MVP 8x admin c-trib
    Jan 10, 2018 @ 13:59
    Alex Skrypnyk
    1

    Hi Alessandro,

    Please, go to Users section -> Your user and check that needed section is checked for you.

    /Alex

  • Comment author was deleted

    Jan 10, 2018 @ 14:30

    Oh great, thank you. I didn't see the "GROUP" menĂ¹ up there all alone, and this tool, immediately deleted my files, the orphans file and folders in media section. This perfectly solved the problem.

    Alessandro

  • Comment author was deleted

    Jan 10, 2018 @ 14:33

    Thank you Alex, that perfectly solved the problem. I didn't see the GROUP menĂ¹ on top right of the screen, as soon I have clicked there, all was clear. The package too did a perfect work.

    Alessandro

  • Alex Skrypnyk 6162 posts 24132 karma points MVP 8x admin c-trib
    Jan 10, 2018 @ 14:34
    Alex Skrypnyk
    1

    Alessandro, glad to help you !!!

    Have a great evening

  • David Armitage 508 posts 2078 karma points
    Jun 21, 2020 @ 04:07
    David Armitage
    0

    Hi Guys

    Anyone having trouble with Umbraco 8. Here is how I do it.

    public void DeleteMedia(int mediaId)
            {
                try
                {
                    IMedia media = _mediaService.GetById(mediaId);
                    if(media != null)
                        _mediaService.Delete(media);
    
                }
                catch (Exception e)
                {
                    _logger.Error<UmbMediaService>("DeleteMedia | Exception: {0} | Message: {1}", e.InnerException != null ? e.InnerException.ToString() : "", e.Message != null ? e.Message.ToString() : "");
                }
            }
    
  • Damien Holley 180 posts 541 karma points
    Jul 13, 2021 @ 00:26
    Damien Holley
    0

    Do you do any code to detect if it is in use?

Please Sign in or register to post replies

Write your reply to:

Draft