Let's isolate the problem.
Are you saying that even if you have this:
Field('up_file', 'upload', uploadseparate=True, requires =[IS_NOT_EMPTY(),
IS_UPLOAD_FILENAME(extension=ext_regex)]),
You can submit a form that does not upload a file into up_file?
On Thursday, 26 December 2013 13:21:35 UTC
More specifically this only happens if I put in the if up_name != None
check to set the filename in the database, otherwise it works well
On Friday, December 27, 2013 11:48:09 PM UTC-5, Massimo Di Pierro wrote:
>
> Let's isolate the problem.
>
> Are you saying that even if you have this:
>
> Fiel
Yes that's exactly the problem!
Which in turn causes the other problems I think
On Dec 27, 2013 11:48 PM, "Massimo Di Pierro"
wrote:
> Let's isolate the problem.
>
> Are you saying that even if you have this:
>
> Field('up_file', 'upload', uploadseparate=True, requires =[IS_NOT_EMPTY(),
> IS_UP
Here is my solution!
if hasattr(request.vars['up_file'],"filename"):
form.vars.filename = request.vars['up_file'].filename
if form.process().accepted:
redirect(URL('data', 'index'))
elif form.errors:
response.flash = "form has errors"
On 28 December 2013 17:08, Calvin Morrison
4 matches
Mail list logo