hasini silva hasini silva - 25 days ago 19
Java Question

Unknown tag (form:option) error

why am I getting unknown tag for

<form:option >
<form:form method="post" >


in spring mvc. How can I solve this?
Thanks

dit dit
Answer

you have to import the form tag. add this to your jsp file:

<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>

also, the form:option should be inside a select:

<form:select path="mySelect">
    <form:option value="0" label="A" />
    <form:option value="1" label="B" />
</form:select>
Comments