Python Django - Saving ContentFile to Local Files -


i'm using contentfile django python , have contentfile uploading web server.

what save contentfile (it pdf) onto local machine.

in : type(file_contents) out : <class 'django.core.files.base.contentfile'>  django.core.files.storage import default_storage path = default_storage.save('/tmp/file.pdf', file_contents)  in:path out:u'/tmp/file.pdf' 

i can't find file anywhere on local machine ... recognize might doing wrong, here great. want able find pdf on local machine see looks like.

the server can't save files local machine. local browser can that. thing server can present file download browser.


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -