Skip to Content
Menu
Dette spørgsmål er blevet anmeldt
1 Svar
3365 Visninger

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
Kassér
Forfatter Bedste svar

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
Kassér
Related Posts Besvarelser Visninger Aktivitet
1
jul. 20
16044
2
jun. 24
4674
0
jan. 21
3623
1
jul. 16
7748
2
okt. 24
3835