Ajay
Ajay

Reputation: 730

org.apache.jasper.JasperException: jsp Unterminated <c:if tag

I want to remove current status from jsp file when a person tries to change his/her status. My code was working fine. I have added c:if and then I have started getting this error. Please correct me where am i going wrong.

  </c:when><c:otherwise>
                    <tr>
                        <td class="label"><bean:message key="changeStatus.new"/></td>
                        <td>
                            <html:select property="memberStatus">
                                <html:option value=""><bean:message key="global.select.empty" /></html:option>
                                <c:forEach var="status" items="${memberStatuses}">
                                    <html:option value="${status}"><bean:message key="changeStatus.${status}"/></html:option>
                                    <c:if test="${status == member.status}" <html:option value="${status}"><bean:message key="changeStatus.${status}"/></html:option>
                                    </c:if>
                                </c:forEach>    
                            </html:select>
                        </td>
                    </tr>

   </c:otherwise></c:choose>

Upvotes: 0

Views: 1789

Answers (1)

Gurkan Yesilyurt
Gurkan Yesilyurt

Reputation: 2675

jsp Unterminated &lt;c:if tag

The problem occurs when you overlooked to add a close tag. So you need close tag &gt;(i.e. > sign) for c:if too.

<c:if test="${status == member.status}" > <html:option ...>
                                        ^
                                       Here

Upvotes: 1

Related Questions