It is a logical problem. The server action has not way to determine which of the three LOAD blocks is doing the submit. This can be solved but I suggest look for a better design that trying to create three identical forms.
On Mar 24, 1:15 pm, Jose <[email protected]> wrote: > Hello, > > why this not work? > > Model: > > tb_prueba = db.define_table('prueba', > Field('nombre'), > Field('archivo','upload') > ) > > Controller (default): > > def subirdoc(): > return dict() > > def form_doc(): > return crud.create(tb_prueba) > > View (default/subirdoc.html): > > <h2>Form 1</h2> > {{=LOAD('default', 'form_doc', ajax=True, ajax_trap=True)}} > > <h2>Form 2</h2> > {{=LOAD('default', 'form_doc', ajax=True, ajax_trap=True)}} > > <h2>Form 3</h2> > {{=LOAD('default', 'form_doc', ajax=True, ajax_trap=True)}} > > does not insert any records (idem for the 3 forms). > > Where that leaves only one form, insert the record, but not upload the > file, only saves the field nombre > > Jose -- You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/web2py?hl=en.

