struts2的token 使用

action中:
@Action(interceptorRefs = {@InterceptorRef("defaultStack"), @InterceptorRef("token")},
			value = "testdrive",
			results={@Result(name = Constants.SUCCESS, location = "/website/testdrive.jsp")}
	)


注意:
需要加此返回
@Result(name = Constants.INVALIDTOKEN, location = "/tokenError.jsp")

你可能感兴趣的:(java,jsp)