TagLib application in JSP (2)

Source: Internet
Author: User

2. Start

Now let's get to know more about the xml application in jsp.

First, define the tld file and the java class file processed by the corresponding tag. Then, use the tag in jsp through the defined syntax,

Let's take a look at the XML file below.

========================= Taglib. tld ================================

PUBLIC "-// Sun Microsystems, Inc. // dtd jsp Tag Library 1.1 // EN"

Http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_1.dtd>

1.0

1.1

Java Pet Store Demo custom tags

Insert

Com. sun. estore. taglib. InsertTag

JSP

An insertion tag

Id

False

True

Template

True

True

Parameter

True

True

CreateTemplate

Com. sun. estore. taglib. CreateTemplateTag

JSP

Create a template object and store in the request with the specified name

Id

False

True

Template

True

True

Screen

True

True

Screen

Com. sun. estore. taglib. TemplateScreenTag

JSP

A template screen object

Screen

True

True

Parameter

Com. sun. estore. taglib. TemplateParameterTag

JSP

A template parameter object

Parameter

True

True

Value

True

True

Direct

True

True
========================================================== ==============================

This is a TLD file in sample ------ Pet Store provided in J2EE Blueprints.

The following describes TLD files.

TagLib Descriptor

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.