Introduction to the properties of nine built-in objects +request objects in JSP and how to apply them

Source: Internet
Author: User

Nine built-in objects for JSPs
Request
Response
Application
Config
Out
Page
PageContext
Session

Exceptionby default, the Iserrorpage property needs to be configured under the page directive to be able to use this property, and the General page does not have this object.
the A:form form is submitted by default as a string. (Very important)
B: Learn to look at the memory address, for example: [java.lang.string.123456...//This memory address is a string array, not a string.
the scope of the C:request (one link).
D: Different request forwarding and redirection: The carrier of the data.
the request in the JSP is equivalent to the httpservletrequest in the servlet
Request.getparameter ("Name value of form element");//The value is obtained by the name value of the form element.
Request.getattrabute ("Name of the attribute");//Gets the value of the passed-in property by the property name
Request.setattrabute (the name of the property, the value of the property);//assigns a value to the property, preceded by the name of the property, followed by the value of the property.
Request.getcontentpath ();//returns the root directory of the project.
Request.getmethod ();//Get submission method, Get/post
Request.getprotocol ();//Get Agreement for example: HTTP 1.1
Request.getquerystring ();//Gets the value after the question mark that is submitted by the Get method.
Request. RemoveAttribute ();//Clear properties.
Request declaration period (one-time link), usage scope, what are the attributes of the application

Original: http://blog.sina.com.cn/s/blog_531101430100lrzt.html

Introduction to the properties of nine built-in objects +request objects in JSP and how to apply them

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.