Anybody else notice the state.md.us email address?
Is this Mark using Struts but to embarassed to admit it?
*rotflmao*
Thai Dang Vu wrote:
class MyUtilBean {
private Collection c;
public Collection getC() {
c = new ArrayList();
c.add(new DataBean("value", "name"));
c.add(new DataBean("value1", "name1"));
c.add(new DataBean("value2", "name2"));
return c;
}
}
.........................
class DataBean {
private String name;
private String value;
// getter and setter methods
....
}
How could I write the <html:options> tag in the input.jsp file so that the jsp
file produces
<select name="...">
<option value="name">value</option>
<option value="name1">value1</option>
<option value="name2">value2</option>
</select>
http://struts.apache.org/userGuide/struts-html.html#options
Basically you'd want to have the 'collection ' attribute refer to the
util bean's Collection var, 'labelProperty' would be 'name' since the
DataBean stores the label in the 'name' var, and 'property' would be
'value', more or less.
Mostly I was just entertained that you and Mark both work in Maryland.
Dave
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]