Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

How to make large file available for download


Go to End


2 Posts   829 Views

Avatar
JohnPrince

Community Member, 1 Post

13 December 2015 at 1:29am

I have a downloads section on my website and I have a DataObject representing each downloadable item.

Now I want to offer some videos for download, up to 500 MB in size. I uploaded them via FTP and I tried to assign them to a UploadField via "From Files", so that they don't have to be uploaded.

The system tells me, that's not possible, because I can only handle file up to 8 MB. How can I avoid this without changin my server settings? I mean, I already did upload the file and only need a reference to it.

Avatar
Devlin

Community Member, 344 Posts

14 December 2015 at 9:38pm

I already did upload the file and only need a reference to it.

Click on the "Sync files" button in the asset admin. Or you could write a File object.

$file = new File();
$file->Name = 'MyFile';
$file->Title = 'MyFile';
$file->Filename = 'assets/Uploads/123/';
$file->ParentID = 123;
$file->write();