struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Konstantina Stamopoulou" <s...@intracom.gr>
Subject Re: logic:iterate question
Date Thu, 14 Feb 2002 11:15:34 GMT
Hi ,

>From what I understand you want to create links for each headline and pass
the head line as a parameter.
So inside the logic:iterate tag U should put :
<logic:iterate.................>
 <jsp:useBean id="info" class="java.util.HashMap"/>
   <%info.put("HeadLineID", "X"); %>

  <html:link page="/details.do" name="info"> Headline </html:link>
</logic:iterate>

U can replace the one line of code with <jsp:setProperty ....of the bean
info>

It worked for me.

Konstantina


---Original Message -----
From: "Oliver Kiessler" <kiessler@linustar.de>
To: "Struts Users Mailing List" <struts-user@jakarta.apache.org>
Sent: Thursday, February 14, 2002 12:58 PM
Subject: logic:iterate question


> hello,
> i have a problem on one of my "views" with a logic:iterate tag. i have
> an "action" that fetches news headlines from a database
> (headline,headlineID) and stores them in a bean
> (headlines->Arraylist,headlinedID->Vector) which is appended to
> request/session. On the "view" i want to iterate through the Arraylist
> with the headlines which basically works fine. but i need to create
> links like this: <a href=ViewHeadlineAction.do?headlineID=X>XYZ</a>
>
> how would i use the iterate tag? do i have to use the nested tag? (i am
> currently using struts 1.0.2) i dont want to use any "java code" in my
> view, only tags...
>
> thanks, oli
>
>
> --
> 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