I try run tomcat with your web.xml (I using older version 3.2.3), its OK no
error message come into view when starting tomcat. (I just modify dtd into
2.2, cause of older version, and save then start up tomcat).


best regards,

ngurah j.

----- Original Message -----
From: "Edward" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: May 31, 2002 3:27 PM
Subject: Why my web.xml is error?


> I have a question about servlet's web.xml file,I put my files into follows
directories:
> D:\Apache Tomcat 4.0\webapps\login\WEB-INF\classes\GetUserIdentity.class
> D:\Apache Tomcat 4.0\webapps\login\WEB-INF\web.xml
> D:\Apache Tomcat 4.0\webapps\login\servlets\index.html
>
> My web.xml is follows:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE web-app
>     PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
>     "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd";>
> <web-app>
>     <session-config>
>      <session-timeout>
>         30
>      </session-timeout>
>     </session-config>
>     <welcome-file-list>
>      <welcome-file>
>         index.html
>      </welcome-file>
>     </welcome-file-list>
>     <servlet>
>         <servlet-name>
>            GetUserIdentity
>         </servlet-name>
>         <servlet-class>
>            GetUserIdentity
>         </servlet-class>
>     </servlet>
> </web-app>        //---------Here is 24 line---------
>
> When I start Tomcat4.0,I got error:
>
> Starting service Tomcat-Standalone
> Apache Tomcat/4.0.1
> PARSE error at line 24 column 12
> org.xml.sax.SAXParseException: The content of element type "web-app" must
match
>
"(icon?,display-name?,description?,distributable?,context-param*,filter*,fil
ter-
>
mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mapping*,w
elco
>
me-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,security-c
onst
> raint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-local-ref*)".
> Starting service Tomcat-Apache
> Apache Tomcat/4.0.1
>
> I don't know why my web.xml is error,how to correct it?
> Thanks!
> Edward
>
>
___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
>

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to