创建session:
ActionContext actionContext = ActionContext.getContext();
Map<String, Object> session = actionContext.getSession();
给创建的session存入值:
session.put(StaticUtil.USERPKID, userInfo.getPkid());
获取session值:
ActionContext ac = ActionContext.getContext();
Map<String, Object> session = ac.getSession();
Integer receiveUserID = (Integer) session.get(sessionValue);
( 或ServletActionContext.getRequest().getSession().getAttribute(sessionValue); )
Struts2获取paramater值:
ServletActionContext.getRequest().getParameter("...");