struts2.5使用通配符时action指定method报错不使用通配符则正常
2017-12-16 22:21
453 查看
HTTP Status 404 - There is no Action mapped for namespace [/test] and action name [SecondAction_hello] associated with context path [/Struct2msb]
配置文件
<action name="*_*" class="com.csy.struct2.{1}" method="{2}"> <result name="success">/{1}_{2}_success.jsp</result> <result name="fail">/{1}_{2}_fail.jsp</result> </action>
**诡异的是
method=”{2}”不使用通配符则正常**
解决办法
在struts2.3之前的版本,正常的配置就可以了,但在struts2.3版本之后,使用通配符调用方法时,内部会验证是否允许访问该方法,所以要加上
方法名1,方法名2…
后续文章持续更新中,微信扫码下方二维码免费关注!,点此查看全部最新文章
我的博客
我的简书
我的GitHub,喜欢的话给个star吧
相关文章推荐
- struts-2.5配置后找不到action,而且只执行index 不执行指定method
- struts2.5框架使用通配符指定方法(常见错误)
- struts2.5框架使用通配符指定方法(常见错误)
- struts2.5框架使用通配符指定方法(常见错误)
- 【转】struts2.5框架使用通配符指定方法(常见错误)
- struts2.5框架使用通配符指定方法(常见错误)
- struts2.5框架使用通配符指定方法(常见错误)
- 【Struts2学习笔记】struts2.5使用通配符配置action跳转
- Struts2一个Action内包含多个请求处理方法的处理,method的使用方法,struts2中的路径问题,通配符映射
- struts2.5框架使用通配符指定方法
- Struts2.5动态方法调用action和使用通配符访问action
- 3.6.4: 配置Action---指定method属性及使用通配符
- struts2.5的method使用通配符无效问题
- There is no Action mapped:关于struts2.5解决通配符无法使用问题
- struts2.5框架使用通配符指定方法常见错误
- struts2.5框架使用通配符指定方法常见错误
- struts2.5之通配符使用报错
- 解决Struts2.5不能使用通配符方式动态方法调用
- 在使用struts的DispatchAction的时候出现Action找不到指定方法的错误
- Struts2.5 通配符不能使用问题