JSP tag meaning and usage list

Source: Internet
Author: User

The following describes the meaning and usage of JSP labels.

<Jsp: include> the tag indicates a static or dynamic file.

<Jsp: forward> the tag indicates redirecting a static html/jsp file or a program segment.

Syntax:

<Jsp: forward page = "path"}/>

Or

<Jsp: forward page = "path"}>

<Jsp: param name = "paramName" value = "paramValue"/> ......

</Jsp: forward>

<Jsp: useBean> A tag is used to create a BEAN instance on the JSP page and specify its name and scope.

Syntax:

<Jsp: useBean id = "name" scope = "page | request | session | application" typeSpec/>

TypeSpec has the following possibilities:

Class = "className" | class = "className" type = "typeName" | beanName = "beanName" type = "typeName" | type = "typeName" |

Note:

In the use of this JSP tag, you must use class or type instead of both class and beanName. BeanName indicates the Bean name in the form of "a. B. c ".

<Jsp: getProperty> the tag indicates obtaining the BEAN property value, converting it into a string, and then inserting it into the output.

<Jsp: setProperty> tag indicates the attribute value in Bean.

<Jsp: setProperty name = "login" property = "username" value = "Paopao"> </jsp: setProperty>

<Jsp: setProperty name = "login" property = "password" value = "Love"> </jsp: setProperty>

<Jsp: plugin> the tag indicates executing an applet or Bean. If possible, you need to download a Java Plug-in to execute it.

The preceding figure shows the meaning and usage of these JSP labels.

  1. JSP Servlet call in tag Library
  2. Step for customizing JSP labels
  3. Introduction to JSP custom tag implementation process
  4. Fully use the tag function to compile JSP application JSTL)
  5. Detailed description of custom JSP labels

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.