一个简单的登陆  做完了  启动tomcat有错误错误如下:
严重: Parse Fatal Error at line 16 column 3: The element type "Resource" must be terminated by the matching end-tag "</Resource>".
org.xml.sax.SAXParseException: The element type "Resource" must be terminated by the matching end-tag "</Resource>".
各位看看什么原因

解决方案 »

  1.   

    对,可能lz吧结束标签写掉了,加上就ok了
      

  2.   

    web.xml<?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee   http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
      <servlet>
        <servlet-name>action</servlet-name>
        <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
        <init-param>
          <param-name>config</param-name>
          <param-value>/WEB-INF/struts-config.xml</param-value>
        </init-param>
        <init-param>
          <param-name>debug</param-name>
          <param-value>3</param-value>
        </init-param>
        <init-param>
          <param-name>detail</param-name>
          <param-value>3</param-value>
        </init-param>
        <load-on-startup>0</load-on-startup>
      </servlet>
      <servlet-mapping>
        <servlet-name>action</servlet-name>
        <url-pattern>*.do</url-pattern>
      </servlet-mapping>
    </web-app>
      

  3.   

    看看你的struts…….xml 配置文件里的结束标签!!
      

  4.   

    struts-config.xml如下<?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.2//EN" "http://struts.apache.org/dtds/struts-config_1_2.dtd"><struts-config>
      <data-sources />
      <form-beans >
        <form-bean name="loginForm" type="com.mldn.lxh.struts.form.LoginForm" />  </form-beans>  <global-exceptions />
      <global-forwards />
      <action-mappings >
        <action 
          attribute="loginForm"
          input="/errors.jsp"
          name="loginForm"
          path="/login"
          scope="request"
          type="com.mldn.lxh.struts.action.LoginAction">
          <forward name="suc" path="/login_success.jsp"></forward>
          <forward name="fal" path="/login_failure.jsp"></forward>
        </action>  </action-mappings>  <message-resources parameter="com.mldn.lxh.struts.ApplicationResources" />
    </struts-config>
      

  5.   

    缺少</Resource>标签,不过应该不是web.xml文件,应该是server.xml或者工程对应的那个xml什么的,本地没装tomcat就不仔细找了
      

  6.   


    你说的好像有点对  可是本机上有tomcat呀
      

  7.   

    7楼是让你检查你本地的tomcat的xml
      

  8.   

    问题解决了  把tomcat重装了一遍就好了