FriendsOfFlarum / upload

The file upload extension with insane intelligence for your Flarum forum.
https://discuss.flarum.org/d/4154
MIT License
177 stars 96 forks source link

Downloading and storing info about files - suggestion #152

Open saleksin opened 6 years ago

saleksin commented 6 years ago

Why don't you just put this files in some directory that is not avaliable from outside, and just take them without this additional downloading? Also this way you could avoid storing full URL.

luceos commented 6 years ago

Why don't you just put this files in some directory that is not avaliable from outside,

Flarum beta 7 has two directories available to store files, assets and storage. Assets is meant to store permanent files for public use. Storage is meant to be private but stores temporary files. Flarum itself is in itself installed inside a public directory, so without extensive installation instructions it's not possible to store files outside of the public directory. With beta 8 this will change, as it adopts a public directory now.

and just take them without this additional downloading?

I wanted to make a fast prototype of the upload extension that could potentially use any adapter. Providing the full URL would be required to support this multitude of adapters. But I've always intended to move towards a better way of loading files.


Thanks for your suggestions, when beta 8 comes out every Flagrow extension will be revisited and improved.