This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Servlets and the fly likes Error 404 resource not found Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Servlets
Bookmark "Error 404 resource not found" Watch "Error 404 resource not found" New topic

Error 404 resource not found

shivang sarawagi
Ranch Hand

Joined: Jun 19, 2008
Posts: 148
I know the basic directory structure under Tomcat is as follows :
webapps/BeerV1/ with WEB-INF/classes directly beneath that.

i built a html form saved it in BeerV1/web directory and copied it under webapps/BeerV1/form.html

also i built a XML DD file web.xml in BeerV1/etc and copied it in BeerV1/WEB-INF
but when i am running http://localhost:8080/BeerV1/form.html

error is occurring 404 resource not found. the default html pages are getting executed. please someone help me out
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13001
Probably Tomcat does not think BeerV1 is a web application due to some problem with your directory structure.

Have you checked the log files for error messages?

How was tomcat installed - as a service or as an application?

Abhay Choubey
Ranch Hand

Joined: Jun 02, 2011
Posts: 34
May be you have some problem in directory structure or check the page name and directory name properly.
shivang sarawagi
Ranch Hand

Joined: Jun 19, 2008
Posts: 148
its working fine now. The link was incorrect in the webxml file. thanks friends.
I agree. Here's the link:
subject: Error 404 resource not found
It's not a secret anymore!