[web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread vinicius...@gmail.com
Hi guys. I'm facing a problem I didn't find a pure web2py solution. I have a SQLFORM.factory() with some fields, including one captcha field. Every time the form is showed, the input captcha field must be empty. The form may have error in other fields and the captcha could be filled right,

Re: [web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread Richard Vézina
Would you show you SQLFORM.factory code? Richard On Wed, Jun 27, 2012 at 4:14 PM, vinicius...@gmail.com vinicius...@gmail.com wrote: Hi guys. I'm facing a problem I didn't find a pure web2py solution. I have a SQLFORM.factory() with some fields, including one captcha field. Every time

Re: [web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread vinicius...@gmail.com
Here it is: http://pastebin.com/2zMNYWnX On 06/27/2012 05:20 PM, Richard Vézina wrote: Would you show you SQLFORM.factory code? Richard On Wed, Jun 27, 2012 at 4:14 PM, vinicius...@gmail.com mailto:vinicius...@gmail.com vinicius...@gmail.com mailto:vinicius...@gmail.com wrote: Hi guys.

Re: [web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread pbreit
Wow, that is some strange code. What does your view code look like? How are you rendering the captcha widget?

Re: [web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread vinicius...@gmail.com
Yes, I was rendering {{=form.custom.widget.captcha}} in my view. Why is this strange? On 06/27/2012 05:58 PM, pbreit wrote: Wow, that is some strange code. What does your view code look like? How are you rendering the captcha widget?

Re: [web2py] How to change a form.vars.field value after validation?

2012-06-27 Thread Bruno Rocha
SO I think you have to inspect and edit the attributes of * form.custom.widget.captcha* * * after the .validate() check the attr's of form.custom.widget.captcha anc change them. *Bruno Cezar Rocha* http://www.CursoDePython.com.br [image: Facebook] http://facebook.com/rochacbruno [image: