Hello all,
I am new to Struts and was experimenting the various HTML tags. I was trying
to improve the code below. Could anyone tell me how I can achieve the same
functionality of filling the select block, but by removing the for loop
from this code(I mean just by filling values with a list).
Michael,
I just use the collection and property value on my html:options, and Struts does
the rest!
ie html:options collection=... property=... (and you can use the
labelProperty if you want too)
Check out the documentation on it...
Dave
Michael Skariah [EMAIL PROTECTED] on 06/26/2001
Thanks Dave,
I will try it out.
-Michael.
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, June 26, 2001 2:33 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: Minimizing the code in JSP file..by removing the for
loop
Michael,
I just
Assuming your List is a bean named list, use
html:options name=list/
Please read the Tag Library Reference for html:options on
http://jakarta.apache.org/struts/struts-html.html#options for details
--
...roland huss
4 matches
Mail list logo