当前位置: 代码迷 >> Java Web开发 >> 大家帮帮忙,Struts分页,提示这个是什么原因啊。
  详细解决方案

大家帮帮忙,Struts分页,提示这个是什么原因啊。

热度:88   发布时间:2007-02-05 16:06:43.0
大家帮帮忙,Struts分页,提示这个是什么原因啊。

TTP Status 400 - Invalid path /search was requested

--------------------------------------------------------------------------------

type Status report

message Invalid path /search was requested

description The request sent by the client was syntactically incorrect (Invalid path /search was requested).


--------------------------------------------------------------------------------

Apache Tomcat/5.0.30


搜索更多相关主题的帖子: Struts  requested  Invalid  提示  

----------------解决方案--------------------------------------------------------

struts-config.xml 配置文件
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN" "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">

<struts-config>
<data-sources />
<form-beans >
<form-bean name="searchForm" type="struts.form.SerachForm" />
</form-beans>


<global-exceptions />
<global-forwards >

</global-forwards>


<action-mappings >
<action
attribute="searchForm"
input="/form/serach.jsp"
name="searchForm"
path="/search"
scope="session"
type="struts.action.SerachAction">
<forward name="search" path="/form/serach.jsp" />
</action>
</action-mappings>
<message-resources parameter="com.yourcompany.struts.ApplicationResources" />
</struts-config>


----------------解决方案--------------------------------------------------------
Invalid path /search was requested
建议看看WEB。XML文件,还有就是你的表单的action的写法

----------------解决方案--------------------------------------------------------

真郁闷,源代码贴不上来.


----------------解决方案--------------------------------------------------------
CONFIG没错的话 自己去页面看看 action=/ 或者.do 的 我以前就是写错这东西
----------------解决方案--------------------------------------------------------
  相关解决方案