I try to use
<select id="_${sec_field}_id" name="${sec_field}" multiple="${multiple}" "${(empty disabled) ? 'disabled' : ' '}" >
To get the <select>
options dynamically enabled/disabled
But Eclipse give me the alerts:
Multiple annotations found at this line:
- Element type "select" must be followed by either attribute specifications, ">" or "/>".
- Attribute """ has no value
So is there any solution that we can work out the disable of html <select>
in JSTL?
Thanks in advance.
Remove those doublequotes around the EL expression which prints the
disabled
attribute name. Doublequotes should be placed around the attribute value only (the part after=
).otherwise you end up with
or
which are syntactically wrong.