Jump to:

4424 Posts in 1267 Topics by 945 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Disable Image/File 'Upload from your computer' option

Moderators: martimiz, Howard, Sean, Ryan M., biapar, Willr, Ingo, swaiba

Page: 1
Go to End
Author Topic: 1363 Views
  • svinkle
    Avatar
    Community Member
    16 Posts

    Disable Image/File 'Upload from your computer' option Link to this post

    I am using FileIFrameField and ImageField in various classes of my site. It seems to be a known issue that you can't select a different directory other than "Uploads" to upload your assets to. I noticed that you can create a new folder in the "Files and Images" part of the CMS. From there you can upload assets to wherever is needed and select the asset at the page level. My questions is: can you disable the radio button on these field types labelled, "With one from your computer"? My thinking is that this will force the editors to use the form on the "Files and Image" part of the CMS to upload new assets. They will still be able to use the "With one from the file store" option for selecting existing assets.

    Or, has the issue of selecting a different directory to upload assets to been fixed?

  • ttyl
    Avatar
    Community Member
    114 Posts

    Re: Disable Image/File 'Upload from your computer' option Link to this post

    sadly nobody answered this question - but I have the same concern. I want to let people select from images an admin has been able to upload via the files tab and *not* to upload arbitrary images from their computer. is it possible to shut off 'from your computer'?

  • swaiba
    Avatar
    Forum Moderator
    1382 Posts

    Re: Disable Image/File 'Upload from your computer' option Link to this post

    Forgive me bringing this old topic up, but I just had a need to ADD the option from your computer.

    This issue (ADD or REMOVING) is based on the users permissions of the 'File' object - in my case thought everyone can upload so I (gasp) hacked the code sapphire\filesystem\File.php with...

       function canCreate() {return true;}

    ... not the best, but I hope it help someone.

    Barry

    1363 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.