Slim3 JSP‎ > ‎

select

This function represents a select option tag.
For example:
<%@taglib prefix="f" uri="http://www.slim3.org/functions"%>

<select name="aaa">
<option ${f:select("aaa", "1")}>One</option>
<option ${f:select("aaa", "2")}>Two</option>
<option ${f:select("aaa", "3")}>Three</option>
</select>

The result:
<select name="aaa">
<option value="1">One</option>
<option value="2" selected="selected">Two</option>
<option value="3">Three</option>
</select>

See demo and sample source.

Next...

Continue to multiselect.


Comments