View Single Post
  #1 (permalink)  
Old 13-07-2008, 12:31
jamesshaw5 jamesshaw5 is offline
new member
 
Join Date: Sep 2007
Posts: 4
Default Try to get servlets working again

Hi there,

I'm back again trying to get my java servlets working with eukhost, and have run into trouble getting requests to hit my servlet.

Here is what I've done so far

1. Created a test servlet and jsp page
2. Created a simple web.xml
3. Wrapped them into a war
4. Uploaded this to /public_html

My problem is that I can't seem to hit the servlet properly. This is the servlet mapping section from my web.xml :

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

When I test this on a local tomcat install its fine, the url

(bah annoyingly I can't post urls as I haven't posted enough on these forums. Imagine these have http on the start )

://localhost:8080/Test/TestServlet

correctly hits the servlet.

But when I try it against my eukhost servet using this url...

://www.jamesshaw.org/Test/TestServlet

...I get an apache error - so it doesn't look like its even reaching Tomcat. I can see that tomcat is definitely there in some respects with this url

://www.jamesshaw.org/Test/

It hits my test index.jsp correctly, and correctly fails because the request hasn't run through the servlet first.

Hopefully someone can suggest what it is I need to do to make this work. I've had a look around and there still isn't much in the way of user guides or FAQs to get a basic servlet setup working so I'm a bit stumped!

Thanks in advance,

James
Reply With Quote