structs-报错01-Document is invalid: no grammar found
程序员文章站
2022-06-22 13:47:06
一时手贱,把structs-config.xml文件中的一段话删了,结果老是报错。
报错内容:document is invalid: no grammar found
[html]
&...
一时手贱,把structs-config.xml文件中的一段话删了,结果老是报错。
报错内容:document is invalid: no grammar found
[html]
<?xml version="1.0" encoding="utf-8"?>
<strong><span style="color:#ff0000;"><!doctype struts-config public
"-//apache software foundation//dtd tiles configuration 1.3//en"
"https://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd"></span></strong>
<struts-config>
<form-beans>
<form-bean name="helloform" type="com.mars.demo01.structs01.form.helloform" />
</form-beans>
<!-- 用于配置actionform -->
<global-exceptions /><!-- 用于配置全局异常 -->
<global-forwards /><!-- 用于配置全局跳转 -->
<action-mappings>
<action attribute="helloform" input="/demo01/demo01_hello."
name="helloform" path="/demo01/demo01_hello" scope="request"
type="com.mars.demo01.structs01.action.helloaction" cancellable="true">
<forward name="show" path="/demo01/demo01_hello.jsp"></forward>
</action>
</action-mappings>
<!-- 用于配置action -->
<message-resources parameter="com.mars.demo01.structs01.applicationresources" />
</struts-config>
然后恢复原样,结果又好了,所以这句话是不能删的。在网上查了查,发现这是一个定义格式的东东。怎么弄的这么麻烦。
报错内容:document is invalid: no grammar found
[html]
<?xml version="1.0" encoding="utf-8"?>
<strong><span style="color:#ff0000;"><!doctype struts-config public
"-//apache software foundation//dtd tiles configuration 1.3//en"
"https://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd"></span></strong>
<struts-config>
<form-beans>
<form-bean name="helloform" type="com.mars.demo01.structs01.form.helloform" />
</form-beans>
<!-- 用于配置actionform -->
<global-exceptions /><!-- 用于配置全局异常 -->
<global-forwards /><!-- 用于配置全局跳转 -->
<action-mappings>
<action attribute="helloform" input="/demo01/demo01_hello."
name="helloform" path="/demo01/demo01_hello" scope="request"
type="com.mars.demo01.structs01.action.helloaction" cancellable="true">
<forward name="show" path="/demo01/demo01_hello.jsp"></forward>
</action>
</action-mappings>
<!-- 用于配置action -->
<message-resources parameter="com.mars.demo01.structs01.applicationresources" />
</struts-config>
然后恢复原样,结果又好了,所以这句话是不能删的。在网上查了查,发现这是一个定义格式的东东。怎么弄的这么麻烦。
上一篇: JSP连接数据库:初学JDBC+access数据库
下一篇: JSP CMS 管理系统
推荐阅读
-
Postman请求后台报错:Invalid character found in method name. HTTP method names must be tokens
-
SpringBoot整合mybatis访问时报错Invalid bound statement (not found)
-
structs-报错01-Document is invalid: no grammar found
-
解决 Tomcat 报错 java.lang.IllegalArgumentException: Invalid character found in method name.
-
Postman请求后台报错:Invalid character found in method name. HTTP method names must be tokens
-
SpringBoot整合mybatis访问时报错Invalid bound statement (not found)
-
eclipse项目导入idea中报错Invalid bound statement (not found)
-
springboot 整合mybatis 报错Invalid bound statement (not found)
-
structs-报错01-Document is invalid: no grammar found
-
解决 Tomcat 报错 java.lang.IllegalArgumentException: Invalid character found in method name.