There is no Action mapped for namespace / and action name AjaxServlet. - [unknown location]
原因:web.xml中配置struts拦截为/*,AjaxServlet被拦截掉
<filter>
<filter-name>struts2</filter-name>
<filter-class>
org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<servlet>
<description></description>
<display-name>AjaxServlet</display-name>
<servlet-name>AjaxServlet</servlet-name>
<servlet-class>org.CollegePro.ssh.web.servlet.AjaxServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>AjaxServlet</servlet-name>
<url-pattern>/AjaxServlet</url-pattern>
</servlet-mapping>
解决办法:修改struts的过滤器设置,如下。只对.aciton结尾的请求和.jsp结尾请求过滤,这样就可以保证Ajax的过滤器能正常使用。
<filter>
<filter-name>struts2</filter-name>
<filter-class>
org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.jsp</url-pattern>
</filter-mapping>
分享到:
相关推荐
前几天在网上下载一个struts2的helloword的例子,那个作者也真够缺德的,搞个错误的程序,害得我查了一天的程序错误。 最后发现竟然是struts.xml被写成啦sturts.xml。 碰见这样的问题先鄙视下提供例子的作者, ...
在Web开发中,尤其是使用基于Java的Web框架如Struts时,开发者可能会遇到一个常见的问题:“HTTP Status 404 - There is no Action mapped for namespace and action name BackMemberGroupAudit”。这个问题通常出现...
Understanding these differences and similarities is essential for managing users and files effectively across different Unix systems. Administrators should refer to specific documentation or manuals ...
Returns the servlet container attribute with the given name, or null if there is no attribute by that name. getAttribute(String) - Method in class javax.servlet.ServletRequestWrapper The default ...
在网上找了好个struts2的例子结果都不好使报There is no Action mapped for namespace / and action name这个错,没办法自己搞了个好用的,myeclipse 6.0 +tomcat5.5 + jdk 1.5 引入项目后直接发布就可以了!
This includes specifying the table name, column names, and other details required for the mapping. - **Hibernate Configuration**: You'll set up the `hibernate.cfg.xml` file, which contains essential ...
- In this approach, I/O devices and memory share the same address space, meaning that no special commands are needed for I/O operations. Instead, I/O operations resemble memory reads and writes. - ...
58:22,466 INFO ] org.springframework.context.support.AbstractApplicationContext.prepareRefresh(AbstractApplicationContext.java:511) - Refreshing WebApplicationContext for namespace 'hessian-servlet': ...
<servlet-name>springapp</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet...
The HX8357-A01(T) is a high-performance TFT (Thin Film Transistor) mobile single chip driver designed for driving 320RGB x 480 dot displays with 262K colors and an internal GRAM (Graphics RAM)....
The HX8340-B(T) is designed to be compact and efficient, making it suitable for mobile devices where space is limited. #### 2. Features The key features of the HX8340-B(T) include: - **Support for ...
本文将针对其中一种常见的错误提示:“There is no Action mapped for namespace / and action name”进行深入分析,并给出相应的解决方法。 #### 二、问题描述 当在使用 Struts 框架开发 Web 应用时,如果配置...
"There is no Action mapped for namespace and action name错误的解决方法.txt"文档可能详细解释了这个问题的成因,如配置错误、Action类未正确指定、或者struts.properties或struts.xml配置文件中的条目缺失。...
switch:<DeviceName> delivers the value 0, when the primary device is active and the value 1 when the backup device is active. For the place holder <DeviceName> in the I/O address the logical name ...
Now make sure that this "ttyUSBx" is set as the destination port, baud rate is 115200, and 8N1 mode for minicom, by running the command 'minicom -s'. Note that running the "minicom -s" command as a ...
- **Address Mapping** (Page 20): Provides details on how addresses are mapped to the memory locations, including sector and page boundaries. #### Device Operation: - **Device Operations** (Page 22): ...
- **Direct Access to Memory**: The entire database is mapped into virtual memory, and all data fetches are performed through direct access to the mapped memory instead of using intermediate buffers or...
17)..Added: Support for relative file paths and environment variables for events and various module paths 18)..Added: Logging in Manage tool 19)..Added: Windows 10 version detection 20)..Added: Stack ...
ELEMENT servlet (servlet-name, servlet-class, init-param*, load-on-startup?, description?)> <!ELEMENT servlet-name (#PCDATA)> <!ELEMENT servlet-class (#PCDATA)> <!ELEMENT init-param (param-name, param...
- **GP_DMA (General Purpose Direct Memory Access)**: GP_DMA is a mechanism for direct memory access, allowing efficient data transfer between memory and peripherals. - **Video Acceleration Block**: ...