If I do upload_to=os.sep, I get an error:
Attempted access to '/test.pdf' denied.
It's trying to upload to the root of the drive!
settings.DOCUMENT_STORE_PATH is something like /var/www/testproject/
documents
file =
models.FileField(storage=FileSystemStorage(location=settings.DOCUMENT_STORE_PAT
On Sep 8, 5:04 am, Dave wrote:
> Hi everyone,
>
> I've found in documentation usage of custom file storage. There it is
> like that
> (http://docs.djangoproject.com/en/1.2/topics/files/#the-built-in-files...
> ) -
>
> from django.db import models
> from django.core.files.storage import FileSyst
Hi everyone,
I've found in documentation usage of custom file storage. There it is
like that (
http://docs.djangoproject.com/en/1.2/topics/files/#the-built-in-filesystem-storage-class
) -
from django.db import models
from django.core.files.storage import FileSystemStorage
fs = FileSystemStorage
3 matches
Mail list logo