Do you have a custom form in the view?

It could be a session problem

Try display

{{=request.session_id}}
{{=response.session_id}}

and see if they match of a new session is issued when the problem
appears.

On Dec 4, 9:59 pm, VP <vtp2...@gmail.com> wrote:
> I have this simple form.  Lately, I've got this very strange problem.
> Occasionally, after I filled out the form and submit.  (See code
> below). The form did not get submitted.  Every field is clear.
> There're no errors (instead the "else" is entered with the message
> "please fill the form".)
>
> I can't replicate it.  But it seems it is occurring more and more.
> Any idea?  Thanks.
>
> @auth.requires_login()
> def add_entry():
>     form = SQLFORM(db.entry)
>     if form.accepts(request.vars, session):
>         redirect(URL('post_process'))
>     elif form.errors:
>         response.flash = 'form has errors'
>     else:
>         response.flash = 'please fill the form'
>     return dict( form=form )

Reply via email to