1.在页面中使用<jsp:forward page="page.jsp"/>时,request中保存的内容会转发到page.jsp,可以在该页面中访问。

   而在页面中使用response.sendRedirect("page.jsp")时,request中保存的内容无法转发到page..jsp页面。

   2.使用forward时,URL不会发生改变;而是用response.sendRedirect("page.jsp")时,URL会显示page.jsp.

 

 

评论
发表评论

您还没有登录,请登录后发表评论

chen-516888
搜索本博客
博客分类
我的相册
1a8a55a2-8a9d-35ea-bba5-9d7fc566e002-thumb
IMG_9122
共 1 张
最近加入圈子
存档
最新评论