given that forms are submitted to the same page, it's the only way for the controller to know what form was indeed submitted :D
On Friday, August 2, 2013 6:19:20 PM UTC+2, lyn2py wrote: > > From the book: > > def two_forms(): > > form1 = FORM(INPUT(_name='name', requires=IS_NOT_EMPTY()), > INPUT(_type='submit')) > form2 = FORM(INPUT(_name='name', requires=IS_NOT_EMPTY()), > INPUT(_type='submit')) > if form1.process(*formname='form_one'*).accepted: > response.flash = 'form one accepted' > if form2.process(*formname='form_two'*).accepted: > response.flash = 'form two accepted' > return dict(form1=form1, form2=form2) > > > I would like to ask the purpose of using formname='form_one'? > > Is it necessary? What does it do? > > > Thanks! > > -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.