这是servlet中的代码:
HttpSession session = request.getSession(true);
session.setAttribute("user", user);
我正在将请求转发到 JSP,我想在其中检查是否附加了会话范围的用户参数。
<c:if test="${??? - check if user is attached to request}">
/ /message
</c:if>
<c:if test="${sessionScope.user != null}">
There is a user **attribute** in the session
</c:if>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)