HTTP Status 404 error [closed]
HI, I have deployed a war named test in the JBoss AS. When i go to browser and type the url http://localhost:8080/test, i get the login.jsp page, which is the welcome page. when i hit the submit button a servlet gets invoked name CheckLoginServlet (onSubmit i have redirected to /test/servlet/CheckLoginServlet), on successful login this servlet redirects to a jsp (MFrame.jsp) which is inside the docroot/main/jsp, and the url looks like this http://localhost:8080/main/jsp/MFrame.jsp?sid=13045798560,and i get a 404 error, the reason is that the url is not including the context "test", now when i explicitly modify the url in the browser to include test in it,(now the url looks like htttp://localhost:8080/test/main/jsp/MFrame.jsp?sid=13045798560) the page successfully renders. My question is why the context test is not coming in the url, as it is the context root开发者_C百科.
my question is why context is not included in the url.
Well the obvious answer is that what ever produced that URL has a bug in it. Beyond that, we'd only be guessing ...
If you'd care to show us the code fragment (or JSP fragment or whatever) in context that created the URL, maybe we could offer a better answer.
Try explicitly setting the context root to "test".
精彩评论