Actually the download method is written in the default controller,  unless
you have written your own function in template.

    {{=IMG(_src=URL('default','download', auth_user.foto))}}

Anyway, could you provide the auth_user table definition?, did you add
extra fields?, Since auth_user.foto.file should return an error,
auth_user.foto should be an upload field to return the file name, if it is
a blob field you should put the result in src with no url.

El mar., 6 de ago. de 2019 12:22, Kimus <[email protected]> escribió:

> olha eu aqui dnv  :)
>
> Estou com um problema eu insiro uma imagem no banco mas na hr de mostrar
> no HTML não consigo de jeito nem um, eu nãoi to  usando o template do
> web2py então td pra mim é mais dificil alguem teria algum jeito de fazer
>
> OBS : eu coloquei um campo extra_field no auth_user como foto e queria
> exibir essa foto, só que não utilizo quase nd do que o web2py tem pronto
> tipo sqlform grid essas coisas dai tenho que fazer mais manual a coisa
> alguem teria como me dar uma luz
>
> To tentando algo do genero  tentei usar a função download que ta na
> default só que no meu controller só que ainda não funciona quando salvo a
> imagem ela upa a imagem no upload  tipo auth_user.foto e uma hash só qe não
> consigo fazer funcionar msm alguem me ajuda :(
>
> <img src="{{=URL(c='template',f='download',args='auth_user.foto.file')}}">
>
> --
> 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 [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/9131340d-6d7a-4d8f-bfa1-3fc0b0001ba7%40googlegroups.com
> <https://groups.google.com/d/msgid/web2py/9131340d-6d7a-4d8f-bfa1-3fc0b0001ba7%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAEz031eXFvo%2BvbkzG3jWw1QKjm%2B%3D0ByCrRFbG_kYxfsPWO%2BeaA%40mail.gmail.com.

Reply via email to