/home.jsp 这样的请求struts2的默认interceptor有没有对它进行处理呢? 如果没有 要怎么样让interceptor对所有请求进行处理?
解决方案 »
- 没招了,Hibernate 的 not mapped 问题
- url汉字参数乱码问题,求解
- 新手小屁孩请教!
- webservice
- java操作xml文件
- Struts2+hibernate+spring整合出现异常,谁能帮帮我
- 在Action中使用FileUpload,把页面的信息从request放到list中,为什么list为0啊?请高手指点!!!!
- 如何比较两个时间差了多少毫秒啊?
- ##########基于Struts的BBS,欢迎大家测试###############
- 使用c3p0连接池的问题
- 关于struts2下使用jquery发ajax请求得不到响应的问题
- 推荐一个自带1.5jre的开源浏览器,精简后的jre只有3m,超精悍
<interceptor name="my"
class="com.jzaccp.web.Intercept.FileIntercept">
<param name="name">my</param>
</interceptor>
在action引用
<interceptor-ref name="defaultStack"></interceptor-ref>
<!-- 引用拦截器,如果引用自定义的拦截器,默认的拦截器要显示指定 -->
<interceptor-ref name="my"></interceptor-ref>
<default-interceptor-ref name="defaultStack"/>
<interceptor-stack name="defaultStack">
<interceptor-ref name="exception"/>
<interceptor-ref name="alias"/>
<interceptor-ref name="servletConfig"/>
<interceptor-ref name="prepare"/>
<interceptor-ref name="i18n"/>
<interceptor-ref name="chain"/>
<interceptor-ref name="debugging"/>
<interceptor-ref name="profiling"/>
<interceptor-ref name="scopedModelDriven"/>
<interceptor-ref name="modelDriven"/>
<interceptor-ref name="fileUpload"/>
<interceptor-ref name="checkbox"/>
<interceptor-ref name="staticParams"/>
<interceptor-ref name="params">
<param name="excludeParams">dojo\..*</param>
</interceptor-ref>
<interceptor-ref name="conversionError"/>
<interceptor-ref name="validation">
<param name="excludeMethods">input,back,cancel,browse</param>
</interceptor-ref>
<interceptor-ref name="workflow">
<param name="excludeMethods">input,back,cancel,browse</param>
</interceptor-ref>
</interceptor-stack>
上面在defaultStack中引用的拦截器都可以在<action>中不经过引用就可以使用
不是请求action
直接是jsp的url