加一个处理GET的方法public class Registration extends HttpServlet
{
         public void doGet(HttpServletRequest req,HttpServletResponse res)
throws ServletException,IOException
         {
                doPost(req,res);
         } public void doPost(HttpServletRequest req,HttpServletResponse res)
throws ServletException,IOException
{ res.setContentType("text/html");
PrintWriter out=res.getWriter();
out.println("<html><body>hhhhhh</body></html>");
}
}