GeeCON Prague 2014*
The moose likes Tomcat and the fly likes http status 404 error is coming Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Products » Tomcat
Bookmark "http status 404 error is coming" Watch "http status 404 error is coming" New topic
Author

http status 404 error is coming

Megha Singhal
Ranch Hand

Joined: Feb 28, 2012
Posts: 225

i am trying to run following jsp and servlets code

"registrationpage.jsp"

"NewServlet.java"


when i am trying to run this program from the url "http://localhost:8080/userregister/registrationpage.jsp"

following error is coming

HTTP Status 404 - /userregister/registrationpage.jsp

type Status report

message /userregister/registrationpage.jsp

description The requested resource is not available.

Apache Tomcat/7.0.40

My directory structure are

C:\Program Files\Apache Software Foundation\Tomcat 7.0\webapps\userregister

under userregister
folders WEB-INF and userregister.jsp

under WEB-INF
classes and web.xml

under classes
NewServlet.java and NewServlet.class
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16101
    
  21

userregister.jsp cannot be located within the WEB-INF directory. That directory and its contents are invisible to web clients as a basic feature of J2EE. Just in case you weren't aware (your info on that could be read 2 different ways).

Beyond that, make sure that whatever userid Tomcat is running under can read TOMCAT_HOME\webapps/userregister/userregister.jsp


Customer surveys are for companies who didn't pay proper attention to begin with.
Megha Singhal
Ranch Hand

Joined: Feb 28, 2012
Posts: 225

Tim Holloway wrote:userregister.jsp cannot be located within the WEB-INF directory. That directory and its contents are invisible to web clients as a basic feature of J2EE. Just in case you weren't aware (your info on that could be read 2 different ways).

Beyond that, make sure that whatever userid Tomcat is running under can read TOMCAT_HOME\webapps/userregister/userregister.jsp


i haven't placed userregister.jsp within WEB-INF it is within the main folder only i.e. in userregister folder.
Megha Singhal
Ranch Hand

Joined: Feb 28, 2012
Posts: 225

please help as i am unable to move further until this problem can't be solved.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: http status 404 error is coming