SSH SSI Java 里面创建session对象,获取getSession,request

1 //获取request请求
2 HttpServletRequest request = ServletActionContext.getRequest();
3 //获取session请求
4 HttpSession sess = ServletActionContext.getRequest().getSession();
5 ActionContext actioncontext = ActionContext.getContext();
6 Map session = actioncontext.getSession();

 

1 Map session=ActionContext.getContext().getSession();
2     session.put("user", qx);

 

posted @ 2012-11-26 10:13  小伙、不一般  阅读(430)  评论(0编辑  收藏  举报