标题:Javaweb中通过request发送请求参数,在jsp中获取,对于sex的情况
只需要多加一个判断即可
<c:if test="${info[2] == '男'}">
<input type="radio" name="sex" value="男" checked="checked"/>男
<input type="radio" name="sex" value="女" />女
</c:if>
<c:if test="${info[2] != '男'}">
<input type="radio" name="sex" value="男" />男
<input type="radio" name="sex" value="女" checked="checked"/>女
</c:if>