Upload hangs when submit is hit

28 views
Skip to first unread message

wswi...@hawk.iit.edu

unread,
Jan 7, 2019, 8:31:59 AM1/7/19
to web2py-users
Good morning,

I have had problems with the buildin upload functionality of the SQLFORM.factory().

When I use code in s4 (see attachments) and type in the actual path to the file, everything works as expected. That being said text field is getting processed as expected. On the other hand, when I use form coded in s3 (see attachments) and hit submit, the form doesn't get processed and hangs indefinitely. I submit a file of size 30kB so it should have issues with its size. In pictures s1 and s2, I show the form and how it looks when it hangs. The form has no problem being processed when I don't select any file.

Does anyone know the reason why this form doesn't get processed. It doesn't work on both Linux and Mac Os.

s1.png
s2.png
s3.png
s4.png

wswi...@hawk.iit.edu

unread,
Jan 7, 2019, 8:37:39 AM1/7/19
to web2py-users
To add more to this post. I truly only need the path to the file not the file itself. 

Anthony

unread,
Jan 7, 2019, 5:17:15 PM1/7/19
to web2py-users
Hard to say without seeing all the code. What are you expecting to do with the uploaded file? Note, using SQLFORM.factory for file uploads can be tricky, as the file is saved with a new filename, which you may then not be recording anywhere if nothing is saved to a database. You must also explicitly specify the "uploadfolder" argument.

Anthony


On Monday, January 7, 2019 at 8:31:59 AM UTC-5, wswi...@hawk.iit.edu wrote:
Reply all
Reply to author
Forward
0 new messages