[web2py] Re: Problem with multiple forms

2011-08-15 Thread Karthik
Thanks weheh, that helped a lot! On Aug 14, 12:12 am, weheh wrote: > Each form needs to have a unique name. I suppose you could use uuid to > make a unique name. Then something like this pseudocode  might work: > > allforms=dict(form_id=new_form_id(),form=SQLFORM(...)) > for f in allforms: >    

[web2py] Re: Problem with multiple forms

2011-08-13 Thread weheh
Each form needs to have a unique name. I suppose you could use uuid to make a unique name. Then something like this pseudocode might work: allforms=dict(form_id=new_form_id(),form=SQLFORM(...)) for f in allforms: if f['form'].accepts(request.vars,formname=f['form_id']): # do something

[web2py] Re: Problem with multiple forms

2011-08-13 Thread Karthik
Is there a way to dynamically name the forms? I don't know how many forms I'll need to display, it depends on an external factor. (I have a textarea and depending on the lines filled in the textarea by the user, I need to create that many forms). Is this possible withing web2py's FORM() helper or

[web2py] Re: Problem with multiple forms

2010-05-06 Thread mdipierro
If you have two forms you have to name them: if form_back.accepts(request.vars, session, formname='back'): ... if form_membership.accepts(request.vars, session,formname='membership'): On May 6, 7:19 am, Sverre wrote: > I'm using this design  in a controller to have buttons on the page: > >