标签:
//XML文件
<servlet-mapping>
<servlet-name>RegServlet</servlet-name>
<url-pattern>/servlet/RegServlet</url-pattern>
</servlet-mapping>
request.getRequestDispatcher("../userinfo.jsp").forward(request,response);
@WebServlet("/RegServlet") //新特性 访问地址直接配置好了
request.getRequestDispatcher("userinfo.jsp").forward(request, response);
request.getRequestDispatcher("/userinfo.jsp").forward(request, response);// ‘/’表示根目录
标签:
原文地址:http://www.cnblogs.com/Val1ant/p/5338857.html