Image in JSP

Hello.

What I was trying to do is to print a image from a database but I磎 not doing the right way... Here is what I磎 doing:

<jsp:text><![CDATA[><HTML>

<IMG SRC='</jsp:text><jsp:expression>linkimagens.get(i)</jsp:expression><jsp:text><![CDATA[' WIDTH='68' HEIGHT='76' ALIGN='BOTTOM' BORDER='0'>>

</HTML>

</jsp:text>

Can someone put me in the right track?

Thanks.

Message was edited by:

RCaseiro

[532 byte] By [RCaseiroa] at [2007-10-3 11:54:37]
# 1

I don't know how to get Image from database. But I suggest the easy way to do this is

1) Store all your image files in a directory.

2) Store name of all the images in the database with full path.

3) while getting records from the database,

<% while(rs.next())

{ %>

<img src='<%=rs.getString("imageurl")%>' width=100 height=100>

<%} %>

harishotya at 2007-7-15 14:29:27 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...