Hi Allan

> I tried:
> 
> http://kes:8080/WinGalagaHST?Op=GetScore
> and
> http://kes:8080/WinGalagaHST/WinGalagaHST?Op=GetScore

I assume 'kes' is a valid IP address - why not start with 'localhost'?

Anyway, I cannot see anything (obviously) wrong with your setup, other than
(as suggested by others) that you should package your class files.

The packages, of course, still get placed under the 'WEB-INF/classes'
directory.

I know for sure that you cannot use un-packaged JavaBeans.

Try packaging your servlets, and let us know how you get on.

One other option you could consider - if you are running Tomcat 4.1x - is to
enable the Invoker Servlet instead of registering and mapping your servlets.

To enable the Invoker Servlet copy and paste the following servlet mapping
code into the 'web.xml' application deployment descriptor:

    <!-- The mapping for the invoker servlet -->
    <servlet-mapping>
        <servlet-name>invoker</servlet-name>
        <url-pattern>/servlet/*</url-pattern>
    </servlet-mapping>

To call your servlet, you need to specify the '/servlet' mapping:

    http://myDomain/myWebApp/servlet/myServlet?x=1

If that works, then you know there is something wrong with the way you have
registered and mapped your servlets in the deployment descriptor.

BTW, the Invoker Servlet should NOT be used in a production environment
because of security issues - so this is just a testing solution.

Regards

Harry


> 
> but both just show HTTP 404 message.  This servlet runs on my friends
> machine, with his own coded web-server, and to get a score, he calls
> ?Op=GetScore.
> 
> Thanks
> Allan
> 
> 
> ----- Original Message -----
> From: "Harry Mantheakis" <[EMAIL PROTECTED]>
> To: "Tomcat Users List" <[EMAIL PROTECTED]>
> Sent: Saturday, January 17, 2004 12:21 PM
> Subject: Re: web.xml config
> 
> 
>> Hello
>> 
>> What is the problem?
>> 
>> How exactly are you calling (requesting) the servlet? - Give us the
> complete
>> URL you are using to invoke the servlet.
>> 
>> Harry
>> 
>>> I have tomcat up and running fine - verified by running the example jsp
>>> pages and servlets.
>>> I have a servlet that I want to get working, called WinGalagaHST which
> is
>>> used for my game I have been developing.  I have put it in my tomcats
>>> webapps directory, and the necessary subdirs like
>>> 
>>> /usr/local/sites/tomcat/tomcat/webapps/WinGalagaHST/WEB-INF/classes
>>> 
>>> I have put the class files in the classes folder (2 of them, called
>>> EDSServlet.class and WinGalagaHST.class), and have my web.xml in the
> WEB-INF
>>> directory.  Is this correct? Below is my web.xml file.  If anybody knows
>>> where I am going wrong, I would much appreciate the help.
>>> 
>>> Thanks very much
>>> Allan
>>> 
>>> 
>>> 
>>> 
>>> -----web.xml
>>> <?xml version="1.0" encoding="ISO-8859-1"?>
>>> 
>>> <!DOCTYPE web-app
>>>   PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
>>>   "http://java.sun.com/dtd/web-app_2_3.dtd";>
>>> 
>>> <web-app>
>>>       <servlet>
>>>               <servlet-name>
>>>                       WinGalagaHST
>>>               </servlet-name>
>>>               <servlet-class>
>>>                       WinGalagaHST
>>>               </servlet-class>
>>>       </servlet>
>>>       <servlet-mapping>
>>>                 <servlet-name>WinGalagaHST</servlet-name>
>>>                 <url-pattern>/WinGalaga</url-pattern>
>>>       </servlet-mapping>
>>> </web-app>
>>> 
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>>> For additional commands, e-mail: [EMAIL PROTECTED]
>>> 
>>> 
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> 
>> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to