2013年10月30日星期三

MyEclipse in action in the JSP Servlet error ah


This is a book on the case , debugging is not passed, dish , said:

index.jsp



Username :

Password :



---------------------------------------------- ------------------------

LoginServlet.java this

package test.servlet;

import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import test.model.LoginModel;
public class LoginServlet extends HttpServlet {
......
}

compilation pass,

But a run index.jsp in the landing point , it appeared the following error

HTTP Status 404 - / JSPSJB / LoginServlet

---------------------------------------------- ----------------------------------

type Status report

message / JSPSJB / LoginServlet

description The requested resource (/ JSPSJB / LoginServlet) is not available.


---------------------------------------------- ----------------------------------

Apache Tomcat/6.0.13


what the problem ah , thank you
------ Solution ----------------------------- ---------------



HelloWorldServlet
HelloWorldServlet


HelloWorldServlet
/ HelloWorldServlet / *


------ For reference only ----------------------------- ----------
web.xml which has not configured this Servlet (LoginServlet);
------ For reference only ------------ ---------------------------
ye configuration ah,


-

-
index.jsp


------ For reference only ----------------------- ----------------
get, thank you


LoginModel
test.model.LoginModel


LoginModel
/ LoginModel



LoginServlet
test.servlet.LoginServlet


LoginServlet
/ LoginServlet

没有评论:

发表评论