<session-config>
<session-timeout>
30
</session-timeout>
</session-config>
答案 0 :(得分:1)
要在session
中设置变量,您无需修改Web.xml
HttpSession session = request.getSession();
String al="am session variable"
session.setAttribute("al", al);
要访问它,您只需执行${sessionScope.al}