- 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
- 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 4、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 5、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 6、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 7、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
forward与redirect!转发和重定向 解析(The forward and redirect! Forward and redirect parsing)
forward与redirect!转发和重定向 解析(The forward and redirect! Forward and redirect parsing)
1. From the address bar
Forward the request from the server resources, direct access to the target server URL address, put the URL of the response content to read, and then the content to the browser. The browser doesnt know the content of the server from where come of, so its address bar or the original address.
Redirect is the service side that sends a status code based on logic, telling the browser to re-request that address. So the address bar shows the new URL.
2. From data sharing
Forward: the forward page and the forwarded page can share the data in the request.
Redirect: no data can be Shared.
3. From the use of place
Forward: when the user logs in, the role is forwarded to the corresponding module.
Redirect: generally used to return home page and jump to other sites when the user logs out.
4. Efficiency
Forward: high.
Redirect: low.
Request. GetRequestDispatcher ( new JSP ). The forward (request, response); / / forward to new. JSP
Response. SendRedirect ( new JSP ); / / redirect to new. JSP
In the JSP page, you will also see the forwarding in the following way:
The JSP: forward page = apage. JSP /
You can also implement redirection in JSP pages:
The % response. SendRedirect ( new JSP ); / / redirect to new. JSP %
The essential difference
Explain a
In a word, forwarding is the behavior of the server, and redirection is the client behavior. Why do you say that? It depends on the workflow of two actions:
Forwarding process: the client browser sends an HTTP request - the inside of the web server to accept this request - call a method inside the container to complete the request processing and forward movement, send the target resource to customers; In this case, the forward path must be the url under the same web container, which cannot be transferred to the other web path, which is the request in its own container. The path shown in the customer browser path is still the fir
您可能关注的文档
- 高空流水——往事三十年(High water - the past 30 years).doc
- 高等数学课程标准(Higher mathematics curriculum standards).doc
- 高精度 π值计算的若千问题(The problem of high precision PI calculation).doc
- 高级食品检验工技能鉴定试题二(Advanced food inspection skills test 2).doc
- 高考专题复习系列讲座——平面向量(Special review lecture series - plane vectors).doc
- 高考化学58个考点精讲 考点3 化学反应中的能量变化(The energy changes in the chemistry reaction of 58 test points of the college entrance examination).doc
- 高考地理大题答题模板(第3版)无需积分(There is no need to integrate the answer template (version 3) of the college entrance exam).doc
- 高考地理常考易错易混点排查整理(The geography of the college entrance examination is easy to be wrong).doc
- 高考地理常见概念必备手册(Necessary manual for the common concept of national college entrance examination).doc
- 高考地理知识点归纳(The geography of the college entrance examination is summed up).doc
- fpc0.0(fpc0.0).doc
- ftpclient listfiles为空解析(Ftpclient listfiles is empty parsing).doc
- F脱盐水题库--问答、实际操作(F desalination water question bank - question and answer, practical operation).doc
- F英语词汇(F English vocabulary).doc
- gaozhong地理(Gaozhong geographic).doc
- GBZ158警示标识(GBZ158 warning signs).doc
- GENFLEX教程(GENFLEX tutorial).doc
- GC1030硬质合金--加工模具用高效长寿命切削刀具材料(GC1030 hard alloy - the tooling is used for cutting tools with high efficiency and long life).doc
- GIS学习日记(GIS learning diary).doc
- GLSL教程(GLSL tutorial).doc
文档评论(0)