Comments (3)
that´s a misunderstanding (probably the documentation is not clear enough):
FILEBROWSER_MEDIA_ROOT: basically the same as djangos MEDIA_ROOT (definition-wise).
FILEBROWSER_DIRECTORY: folder withhin MEDIA_ROOT
it´s good to save "uploads" with the filebrowsefield, because when you need to serve your media, "uploads" is not within djangos MEDIA_ROOT and therefore needs to be saved to the database.
from django-filebrowser.
Then there is no point of having FILEBROWSER_MEDIA_ROOT setting if it can't be changed.
It's good to keep "uploads" out of database if
FILEBROWSER_MEDIA_URL = "/uploads/"
or
FILEBROWSER_MEDIA_URL = "http://uploads.example.com/"
from django-filebrowser.
The commit above adresses this issue. You can now set FILEBROWSER_MEDIA_ROOT
in order to browse files from a path different from Django's MEDIA_ROOT
.
However, the preferred way to customize FB's media root and media url is to set these parameters on a custom storage object (see http://readthedocs.org/docs/django-filebrowser/en/latest/file_storages.html). It can be expected that FILEBROWSER_MEDIA_ROOT
and FILEBROWSER_MEDIA_URL
will not be used in the next major release of FileBrowser.
Regarding the other issue of having DIRECTORY
(e.g., 'uploads/') saved in a database: This will stay as it is. Backward compatibility is one reason. The other reason is that you may work around the problem you're facing by setting FILEBROWSER_DIRECTORY=''
(an empty string) and changing the storage engine's location (FILEBROWSER_MEDIA_ROOT) to whatever you like (e.g. MEDIA_ROOT + 'uploads/'
).
from django-filebrowser.
Related Issues (20)
- Modal position is out of the window. HOT 5
- Refused to connect HOT 8
- Frame loaded with http protocol HOT 4
- No clear settings HOT 4
- Select buttons disappear when Filebrowser called from CKEditor after upgrade HOT 1
- Issue with latest version
- 未来filebrowser是否考虑会添加webdev支持
- Add a `--force` flag to `python manage.py fb_version_generate`
- Should remove providing_args from the Signals
- ifequals is depreciated HOT 1
- FileBrowser is not compatible with Django 4? HOT 2
- FileBrowser permissions HOT 2
- override upload_to on save model method HOT 4
- Files with more than one extension (examples: .tar.gz, .tar.xz) are not permitted by _isAllowedExtension in filebrowser.js HOT 1
- Broken thumbnail with default settings HOT 1
- admin permission HOT 1
- doesnt work with pillow 10, please fix requirements.txt HOT 1
- Moving files between folders HOT 2
- Use absolute path for directory HOT 1
- Make Grappelli optional HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-filebrowser.