try to modify the context definition:

<context path="/" docbase...>



-----Message d'origine-----
De : Chris Andreou [mailto:[EMAIL PROTECTED]]
Envoyé : mercredi, 11. avril 2001 18:05
À : '[EMAIL PROTECTED]'
Objet : RE: Servlet registration


I didn't make a difference.  I am frustrated


my context path definition is

<context path=""
docBase="e:/wwwroot/dgms_dev"
reloadable="true" />

my Host name is trw02
I am hitting the server by
http://trw02/servlet/SimpleExample  does not work
http://trw02/servlet/examples.SimpleExample  works
http://trw02/servlet/simple does not work

Chris




-----Original Message-----
From: Julien, Timothy [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 10:48 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Servlet registration


The whitespace in your <servlet-mapping> in your web.xml could be leading to
the failure you see.
try:
<servlet-mapping>
          <servlet-name>SimpleServlet</servlet-name>
          <url-pattern>/simple</url-pattern>
</servlet-mapping>

what URL are you attempting to hit from your browser?

Tim Julien
HP middleware

-----Original Message-----
From: Chris Andreou [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 11:37 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Servlet registration


I have the same problem.

I have put my servlets under the WEB-INF/classes:

For example:
directory structure
WEB-INF/classes/examples.SimpleServlet

web.xml file

  <servlet>
     <servlet-name>SimpleServlet</servlet-name>
     <servlet-class>examples.SimpleServlet</servlet-class>
  </servlet>


   <servlet-mapping>
          <servlet-name>
          SimpleServlet
          </servlet-name>
          <url-pattern>
          /simple
          </url-pattern>
  </servlet-mapping>


httpd.conf:
JkMount /*.jsp ajp12
JkMount /servelt/* ajp12


I am able to see the servlet using a complete path
http://trw02/servlet/examples.SimpleExample

but not using the names in web.xml

Based on the documentation and examples I am doing right. Please any
suggestions are welcome

Thanks in advance

Chris


-----Original Message-----
From: Ron Pitts [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 9:57 AM
To: [EMAIL PROTECTED]
Subject: RE: Servlet registration



Zsolt,

Your missing some stuff

webapps/myapp/WEB-INF/classes     - store servlets/jsp in here

put your web.xml in
webapps/mysql/WEB-INF/


-----Original Message-----
From: Zsolt Horvath [mailto:[EMAIL PROTECTED]]
Sent: 11 April 2001 15:55
To: [EMAIL PROTECTED]
Subject: Servlet registration


Hi !

How could I register my own servlets into TomCat ??

I put them into the %TOMCAT_HOME%/webapps/myapp/Web-inf/classes directory.
After I create a web.xml file in the %TOMCAT_HOME%/webapps/myapp directory.
The web.xml file contains this:

<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">

<web-app>

    <display-name> Web Application</display-name>

    <servlet>
      <servlet-name>Servlet1</servlet-name>
      <servlet-class>Servlet1</servlet-class>
    </servlet>

    <servlet-mapping>
      <servlet-name>Servlet1</servlet-name>
      <url-pattern>/Servlet1</url-pattern>
    </servlet-mapping>

</web-app>

And I restarted the tomcat, but it doesn`t work ! What`s wrong?
Please help for me: [EMAIL PROTECTED]

Reply via email to