+5

Is it possible for flask upload to upload a file from any directory?

Right now I have a code that have the app.config['UPLOAD_FOLDER'] have a static value. Whatever is the path that is declared to the app.config['UPLOAD_FOLDER'] is the only path of the file that can be uploaded.

8/19/2019 2:40:38 AM

Raisa Ramos

3 Answers

New Answer

+1

What I did now was I save the file first in the folder that I declared in the app.config['UPLOAD_FOLDER'] before accessing it.

0

yea, of course you can do that with sys.dir()

0

sys library has these functions that can help you to return address or remove some file.