The tag has an attribute value.
http://struts.apache.org/userGuide/struts-html.html#select
The value to compare with for marking an option selected. [RT Expr]
HTH,
Glenn
<[EMAIL PROTECTED]>
27/09/2005 12:08 PM
Please respond to
"Struts Users Mailing List"
To
cc
Subject
u
From: <[EMAIL PROTECTED]>
This works fine and I can save the correct value to the database. The
question I have is how do I display the same option tag when updating
the user and the details are returned from a database.
The same JSP snippet you posted should work in both the 'add' and 'edit'
Hi All,
I am using the html option tag embedded within the html select tag to
select a value from a drop down list as follows:
Mr
Mrs
This works fine and I can save the correct value to the database. The
question I have is how do I display the same option
Here is the solution for the issue I raised. Yeah, it is a dumb question.
If it is only one preselected vlaue then use "value" in html:select.
The catch here that I understood later is property in html:select should be
array of strings if strings are displayed in the option list.
Let me rephrase my question here..
has "value" attribute that is to be populated if one of the
options is to be pre-selected.
What if I have to pre select multiple options.. may be using optionCollections
etc. something like html:select having a "value[]" so that I can put in all
values tha
How would I see that an element is pre-selected or highlighted just the
way it happens with selected keyword in regular tag..
What I am trying to do here is populate a collection of objects on
multi-select box, some of them pre-populated. I tried
http://mail.yahoo.com
Yes, form field values (generated by the Struts tags) are synced with
corresponding ActionForm field values when the page is rendered. So you
can override the ActionForm's reset method to specify initial values.
But typically you only want to do this when you are showing a fresh
"add" form, not
Hi there,
Is it possible to pre-select a value from a dropdownlist htm:option
tag?
Thanks
Iván Corvillo
Iconic, SL
Molinot 53
Pol.Ind.El Camí Ral
08860 Castelldefels
Tel: 902 195 962 / 93 419 54 45
Fax: 93 636 21 42
[EMAIL PROTECTED]
-
8 matches
Mail list logo