jsp获取SessionID值

<%
HttpSession s = request.getSession();
s.setAttribute("name","test");
%>
Session属性值:<%=s.getAttribute("name") %>
SessionID:<%=s.getId()%>

posted @ 2016-06-24 15:21  N神3  阅读(2649)  评论(0编辑  收藏  举报