Reputation: 33
Here is the sample web.xml code :
<servlet>
<servlet-name>register</servlet-name>
<servlet-class>RegisterServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>register</servlet-name>
<url-pattern>/Registration</url-pattern>
</servlet-mapping>
While opening the page Registration on my browser(am using tomcat 7.0),it shows the error :
The requested resource (/yaman/proj/Registration) is not available. (404 error)
Even when i remove all the files from the class folder,it says the same,as expected.
Cant identify where exactly does the problem lie.
Please help!
Upvotes: 0
Views: 243
Reputation: 33
I was having a really weird error,and i have no idea why it happened.
All my files for my project were listed under webapps/yaman/proj/ ..when i was using tomcat to register myself using a register.jsp page(which was intern mapped to a servlet using web.xml),it gave me a 404 error,saying the resource is not available.
But when i cut and paste all the files from "proj",copied it to "yaman" and deleted "proj",it somehow worked and the servlets also worked fine.
I have no idea why such an error arised.
If any of you folks have an idea why this happened or experienced same sort of problem,feel free to add comments.
Upvotes: 1