Jsp tags, Fields

Source: Internet
Author: User

1. JspTags are the logical business functions provided.JspWrite inJavaCode, the main labels are

<Jsp: include page = ""> </jsp: include>Can contain otherJspFile, which can be directly added to double quotation marks

<Jsp: foward page = ""> </jsp: iorward>To jump to the tab page, you can directly add

<Jsp: parma value = "" name = ""> </jsp: prma>You can directly add a value to the double quotation marks by using the value transfer label.FowardLabel usage

2.What is the difference between dynamic and static introduction?

<Jsp: include>Is involved in dynamic label Introduction2ItemsJspThe file will be translated into twoServletThe two files are merged for execution.

IncludeIt is the two involved in static introduction.JspThe file is translated into oneServletThe two files are merged in the source file for execution.

3.IngJsp

IngJspInJspIntroduced inHtmlFile. The ing syntax is

<Servlet>

<Servlet-name> *** </servlet-name>

<Jsp-file> *** </jsp-file>

<Load-on-startup> *** </load-on-startup>

</Servlet>

<Servlet-mapping>

<Servlet-name> *** </servlet-name>

<Url-pattern> *****. html </url-pattern>

</Servlet-mapping>

AddHtmlFile, you can mapJsp

4. 4Domain objects

Pagecontext (pageDomain)

Request (requestDomain)

SessionDomain)

Servletcontext (applicationDomain)

1What is a domain?

Is the scope of the function.

2, This4Domain lifecycle?

PageThe domain is valid only on the current page and ends when you leave the page.

RequestAfter the domain sends the request,

SessionThe domain is a session and ends after a session is completed.

ApplicationThe domain is the wholeWebProgram

3And when to use the object domain

PageIf the domain is valid on the current page

RequestWhen the domain is used up by others

SessionWhen the domain is used by itself, it can be used by itself after a period of time.

ApplicationWhen the domain is used by itself, not only can it be done by yourself, but also by others

Related Article

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.