Servlet 两种跳转方式

  response.sendRedirect , // 重定向,服务器端将uri返回到客户端,客户端再次发送请求。

  RequestDispatcher  rd  =  getServletContext().getRequestDispatcher("/login.jsp"); 

  rd.forward(request,response);  //跳转,直接从服务器端访问 uri

原文地址:https://www.cnblogs.com/shouwangzhe-/p/3909327.html