Hello sorry my bad english and i hope that you understand my problem. 

I want show in one page all pictures which are saved in database.
In page i want that i can upload new picture and update it whit forms 
(override old one)
My code are

in controller:
def jobs():
    images=db().select(db.ref.id,db.ref.file)
    for img in  images:
        formname = "upload_f_%s"%img.id
        form = FORM(INPUT(_type="file",_name=formname), 
INPUT(_type='submit'))
        
        if form.accepts(request.vars, _name=formname):
                response.flash = form.vars
                
    return dict(form=form, img=img, formname=formname, images=images)

in views:
{{for img in images:}}
   <image><img width="85px"
     src="{{=URL('download', args=img.file)}}" /><br></image>
     <br><br><br><br><br>        
        {{=img}}
        {{formname=img.id}}
        {{=formname}}
        {{=form}}
        {{pass}}{{pass}}

please help!

Reply via email to