Struts2.5以上版本There is no Action mapped for namespace [/] and action name [userAction_login] associated with context path []
分析:Struts2在2.5版本后添加strict-method-invocation(严格方法访问),默认为true,不能使用动态方法调用功能,故需设为false
struts.xml设置如下:
<package name="p1" extends="struts-default" namespace="/"strict-method-invocation="false">
<!--配置全局的结果视图-->
<global-results>
<result name="login" type="redirect">/login.jsp</result>
</global-results>
<!--配置jsp页面的访问规则-->
<action name="page_*_*">
<!--1:第一个*,2:第二个*-->
<result name="success">/WEB-INF/pages/{1}/{2}.jsp</result>
</action>
<!--用户模块-->
<action name="userAction_*" class="com.gyf.bos.web.action.UserAction" method="{1}">
<result name="home">/WEB-INF/pages/common/index.jsp</result>
<result name="loginfailure">/login.jsp</result>
</action>
</package>
推荐设置:namespace="/"
提示:因为SSH项目已经有很多年头了,使用时要考虑到版本问题。
Struts2.5以上版本There is no Action mapped for namespace [/] and action name [userAction_login] associated with context path []的更多相关文章
- struts2中错误There is no Action mapped for namespace [/] and action name [] associated with context path
1 There is no Action mapped for namespace [/] and action name [] associated with context path [/Stru ...
- struts2方法无法映射问题:There is no Action mapped for namespace [/] and action name [m_hi] associated with context path []
使用struts的都知道,下面使用通配符定义的方式很常见,并且使用也很方便: <action name="Crud_*" class="example.Crud&q ...
- Struts2中关于"There is no Action mapped for namespace / and action name"的总结
今天在调试一个基础的Struts2框架小程序.总是提示"There is no Action mapped for namespace / and action name"的错误. ...
- eclipse中配置struts2出现There is no Action mapped for namespace [/] and action name [Login] associated wi
下午在eclipse中配置struts2时报: There is no Action mapped for namespace [/] and action name [Login] associat ...
- 报错:HTTP Status 404 - There is no Action mapped for namespace [/] and action name [product-save] associated with context path [/20161101-struts2-2].
运行:index.jsp---->input.jsp----->details.jsp,但是在input.jsp到details.jsp的时候报错误. 异常如下: 严重: Could no ...
- Struts2-tomcat报错:There is no Action mapped for namespace / and action
HTTP Status 404 - There is no Action mapped for namespace / and action name first. type Status repor ...
- There is no Action mapped for namespace [/pages/action/student] and action name [findStudent]
1.错误描写叙述 2014-7-13 2:38:54 org.apache.jasper.compiler.TldLocationsCache tldScanJar 信息: At least one ...
- There is no Action mapped for namespace / and action name UserAction
果断收藏了,说的非常具体.刚開始学习的人常常遇到的问题. There is no Action mapped for namespace / and action name UserAction 在网 ...
- Could not find action or result: There is no Action mapped for namespace [/] and action name [GetG
Could not find action or result: /car/GetGpsDataAction There is no Action mapped for namespace [/] ...
- eclipse使用SSH框架出现There is no Action mapped for namespace [/] and action name [] associated with context path错误
eclipse使用SSH框架出现There is no Action mapped for namespace [/] and action name [] associated with conte ...
随机推荐
- idea 更新后和新的直接安装前,都需要配置 idea64.exe.vmoptions 后再使用
配置合适的参数提升性能,默认的性能不高
- jquery 登录判断遇到的小问题
1.碰到的第一个问题是: 往body上加载check,用load不管用,可以用ready试试. 2.原来jquery里获取用的val(),我一直以为是value()... 尴尬 3.两个标志位是为了判 ...
- oracle字段like多个条件
写oracle sql时有时候会有 and (字段 like ‘匹配串1’or 字段 like ‘匹配串2’or ...)这样的情况出现,下面提供一个简洁点的解决方案: and REGEXP_LIKE ...
- Emacs Python 自动补全之 eglot
eglot 个人水平有限,自己的测试难免有不足甚至错误的地方.欢迎各位emacser 能前来留言交流. 首先eglot 是一个lsp-mode的集成环境.作者说这不仅仅是一个lsp工具.但是我从其说明 ...
- python3.6+RF环境搭建
现在大家都在用python3了,利用这个机会正好把自己的练习重新整理一遍,本篇记录用python3.6重新搭建关键字驱动环境 目录 1.安装python3.6 2.安装wxPython 3.安装rob ...
- java:多线程(代理模式,Thread中的方法,Timer,生产者和消费者)
*进程:一个正在运行的程序,进程是操作系统分配资源的基本单位,每个进行有独立的内存空间,进程之间切换开销较大. *线程:一个轻量级的进程,线程是任务调度的基本单位,一个进程可以有多个线程, * 系统没 ...
- Python学习之并发基础知识
8 并发编程 8.1 基础知识 8.1.1 操作系统的定义 操作系统是存在于硬件与软件之间,管理.协调.调度软件与硬件的交互. 资源管理解决物理资源数量不足和合理分配资源这两个问题, 通俗来说,操作系 ...
- 【VS开发】ActiveX开发注意事项
[VS开发]ActiveX开发注意事项 标签:[VS开发] 注意:必须在工程的app文件的InitInstance()中加入如下代码,否则动态创建控件不会成功: AfxEnableControlCon ...
- jinja2模板接受
from flask import Flask,render_template app = Flask(__name__)#template_folder='templates',默认就是templa ...
- Flask的 sqlalchemy 操作要点
1.filter和filter_by的区别 filter,使用复杂的过滤条件,一般用两个等号进行匹配 filter,使用简单的过滤条件,一般用一个等号进行匹配 Answer.query.filter( ...