Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
3335 Zobrazení

I created a page on the website in which the user uploads an excel file (using form input type = "file") and I process it in the controller. but where is the path of the uploaded file? Is it saved in the database? is the file deleted after it is uploaded?

Avatar
Zrušit
Autor Nejlepší odpověď

Figured it out myself:

Uploading a file using HTML form creates a werkzeug.FileStorage object and it won't save in a location. You can save it using file.save(dst='//path') in the controller after reading the file.



Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
1
čvc 20
16012
2
čvn 24
4661
0
led 21
3606
1
čvc 16
7737
2
říj 24
3800