I have noticed that the value attribute of the select
tag, which is said to be a run-time expression in the 
struts tag documentation, does not seem to work that way.

I have the following select statement:
<html:select property="<%= OrganizationForm.PARENT_ORG_ID %>" 
        
value="<%=OrganizationForm.PARENT_ORG_ID %>">
        <html:options collection="<%= Constants.ORG_LIST %>" 
                        property="<%= Constants.SELECT_VALUE %>"
                        labelProperty="<%= Constants.SELECT_LONG_NAME %>"/>
</html:select>

where I want to use the same variable to initialize the select statement,
and also to get set by the selected value after the user makes a selection.

This does not work.  I always get the first item in the list.  However, 
if I substitute this:
<html:select property="<%= OrganizationForm.PARENT_ORG_ID %>" value="24">
        <html:options collection="<%= Constants.ORG_LIST %>" 
                        property="<%= Constants.SELECT_VALUE %>"
labelProperty="<%= Constants.SELECT_LONG_NAME %>"/>
</html:select>

where 24 is one of the valid ids, it correctly selects the option that
cooresponds to 24.

Am I doing something wrong, is this a bug in the tag, or perhaps
a bug in the documentation?

-- Larry Maturo
   [EMAIL PROTECTED]


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to