[Struts 2 + EJB 3] Display an image

2009-11-27 Thread Fernandes Celinio
Hi, I have an entity bean which has a BLOB attribute. That BLOB attribute maps to a BLOB column in a table in an Oracle database. @Entity public class Boo implements Serializable { ... @Lob @Basic(fetch=FetchType.LAZY) private byte[] image; public byte[]

Re: [Struts 2 + EJB 3] Display an image

2009-11-27 Thread Saeed Iqbal
Are you putting the file name in session string or the binary file? On Friday, November 27, 2009, Fernandes Celinio cfernan...@sopragroup.com wrote: Hi, I have an entity bean which has a BLOB attribute. That BLOB attribute maps to a BLOB column in a table in an Oracle database. @Entity

Re: [Struts 2 + EJB 3] Display an image

2009-11-27 Thread Paweł Wielgus
Hi Fernandes, i think that it is impossible what You are trying to achieve. You cannot pur image to img tag inside html. Img tag will result in just another http request, and this another request must be serviced by your server. So the code will look like this: img src=/showMyimage.action?id=123

RE: [Struts 2 + EJB 3] Display an image

2009-11-27 Thread Fernandes Celinio
Hi, Thanks for helping. Well, I of course needed to call the action in my img tag. It works. Thanks again. -Message d'origine- De : Paweł Wielgus [mailto:poulw...@gmail.com] Envoyé : vendredi 27 novembre 2009 13:04 À : Struts Users Mailing List Objet : Re: [Struts 2 + EJB 3] Display