What are the two ways to jump in JSP? What's the difference?

Source: Internet
Author: User
There are two ways of jumping in a JSP
  1. Forward Jump: <jsp:forward page = "Jump pages Address" >
  2. Response Jump: Response.sendredirect ("jump page address");

The differences between the two types of jumps are as follows

  1. Forward Jump:
    1. Server-side jump, the address bar does not change.
    2. Execute the jump immediately after execution to the jump statement, and then the code is no longer executed (be sure to release all resources before jumping).
    3. The properties of the request setting are still available on the page after the jump.
  2. Response Jump:
    1. The client jumps and the address bar changes.
    2. Jump after all code execution is complete.
    3. The page cannot use the request on the previous page after the jump.
    4. Use address rewriting to pass parameters (Response.sendredirect ("URL? parameter name = parameter value")).


What are the two ways to jump in JSP? What's the difference?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.