[phpBB Debug] PHP Notice: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3824: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3247)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3826: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3247)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3827: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3247)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3828: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3247)
Next Framework • Ver Tópico - Exibir imagem - Resolvido

Exibir imagem - Resolvido

Não deixe de perguntar, solucione aqui suas dúvidas...

Exibir imagem - Resolvido

Mensagempor tchaco » Seg Out 18, 2010 9:16 pm

Editado pela última vez por tchaco em Ter Out 19, 2010 6:36 pm, num total de 1 vezes
tchaco
 
Mensagens: 28
Data de registro: Ter Abr 06, 2010 9:37 am

Re: Exibir imagem

Mensagempor rogelgarcia » Ter Out 19, 2010 6:05 pm

É necessário ter permissão para acessar as imagens.. caso contrário o servidor não irá retorná-las mesmo não. Isso é uma questão de segurança.

A forma mais simples de informar ao servidor que o usuário pode ver a imagem.. é colocar um <t:property> para ela.. exemplo:

<t:property name="foto"/>

Isso irá exibir um link para download exatamente como o que vc mostrou no seu código e também irá liberar a permissao no servidor para exibir a imagem.

Imagino que você não deseje mostrar esse llink.. e sim o <img>.. nesse caso.. utilize comentários de HTML ao redor do <t:property>.. ele será executado (liberando a permissao).. mas não será mostrado...

O seu jsp completo ficaria da seguinte forma (o n:panel não é obrigatório, mas ajuda caso as propriedades estejam sendo renderizadas em duas colunas..):

<n:panel>
<!--
<t:property name="foto"/>
-->
<img src="/sis/DOWNLOADFILE/${estoque.foto.cdfile}" height="75px" width="100px" />
</n:panel>
rogelgarcia
Administrador
 
Mensagens: 674
Data de registro: Qua Jul 08, 2009 9:02 am

Re: Exibir imagem

Mensagempor tchaco » Ter Out 19, 2010 6:35 pm

Valeu Rogel, funcionou.

Obrigado.
tchaco
 
Mensagens: 28
Data de registro: Ter Abr 06, 2010 9:37 am


Retornar para Dúvidas

Quem está online

Usuários vendo este fórum: Nenhum usuário registrado online e 2 visitantes

cron