Hi!!!

I have a form created using Helper HTML, It is has manye field

form = FORM(TABLE(

TR(TD(LABEL("Foto 1:",_class="label_foto5"),
INPUT(_class="upload",_id="foto5",_name="foto5", _type="file",
                                                                
_onchange="leerarchivobin('foto5','loadfoto5')")),
                  TD(LABEL("Foto 
2:",_class="label_foto6"),INPUT(_class="upload",_id="foto6",_name="foto6", 
_type="file",
                                                                
_onchange="leerarchivobin('foto6','loadfoto6')")),
                  TD(LABEL("Foto 
3:",_class="label_foto7"),INPUT(_class="upload",_id="foto7",_name="foto7", 
_type="file",
                                                                
_onchange="leerarchivobin('foto7','loadfoto7')")),
                  TD(LABEL("Foto 
4:",_class="label_foto8"),INPUT(_class="upload",_id="foto8",_name="foto8", 
_type="file",
                                                                
_onchange="leerarchivobin('foto8','loadfoto8')")),),
                
               TR(TD(IMG(_id="loadfoto5")),
                    TD(IMG(_id="loadfoto6",_height="300px")),
                    TD(IMG(_id="loadfoto7")),
                    TD(IMG(_id="loadfoto8"))
                )))


When I retrieve data from database I set data in the form this manner.

form.vars.campo_1 = item.campo_1
....
....
form.vars.campo_n = item.campo_n

¿How do I to set image in field type upload?.  For example, in my table I 
have next definition:

Field('foto1', 'upload',label=T('Foto 1 - Cliente'))

Thanks in advance.

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
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/d/optout.

Reply via email to