struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Frederic Houbie - ABSIS-GROUP <j...@absis-group.be>
Subject RE: html:img tag question
Date Tue, 06 Nov 2001 09:37:04 GMT
Hi,

I tried this, but the code is not interpreted

here is what I get in my html page

<img src="/images/<%=CellID.getCellCarFichierimage()%>">

Why, in fact, i need something more simple. The src attribute comes from a
db field which is in my iterated array.

How can I do that, here is what I wrote in my jsp file
<html:img src="/images/<%=CellID.getCellCarFichierimage()%>" />

Thanks

-----Original Message-----
From: Balasubrahmanyam Pasumarthy [mailto:bpasumar@cisco.com]
Sent: lundi 5 novembre 2001 12:42
To: Struts Users Mailing List
Subject: Re: html:img tag question


Build a Image class and keep a member with int value and write set/get
methods.
Keep an array of that Image class in Action Form and Iterate thru it like
this way.


<logic:iterate id="image" name="currentActionForm" property="images">
<html:img
src="Image<%=Integer.toString(((Image)image).getImageNumber())%>"/>
</logic:iterate>

Hope this helps

At 11:26 AM 11/5/01 +0100, you wrote:
>Hi ,
>
>I need to create a page that use the html:img tag. the link to build must
be
>dynamic, it is in a logic:iterate loop.
>In my loop, I have a variable that contain a id. I want to build a dynamic
>src file name for my html:img tag that must look like
><img src='image123'>
>
>where 123 is the value if my ID.
>
>How can I do that ?
>
>Thanks
>
>Frederic

Balasubrahmanyam Pasumarthy
**************************************
Sr. Consultant
Zensar Technologies Ltd,
Ph:     91-20-6684001 extn 612
         9822114193 (mobile)
***************************************


--
To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:struts-user-help@jakarta.apache.org>




--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message