Recently do a tree-shaped structure of the display, request the target page, the background only return a simple list, although there is a desire to do some work in the JSP page simplification, but too cumbersome, other tags can not meet the needs,
Severe: servlet. Service () for servlet JSP threw exception
Org. Apache. Jasper. jasperexception:/selectortagtest. jsp (26,8) According to TLD or attribute directive in Tag file, attribute items does not Accep
T any expressions
At org. Apache.
This is a helloworld program.
Problems solved: 1. The project cannot be processed using EL expressions; 2. How should TLD be defined; 3. Custom a JSP tag
1. The El expression cannot be used.
(I am using the tomcat.6.0.36 version I just downloaded
Horizontal slotWith TLD files, we can customize a method label for use in the page, and the directory is usually placed in the TLDs folder below the Web-inf:Introduction to an example of a TLD tag file directly on the JSP: @ taglib Prefix = " FNS "
Sometimes when writing a front-end JSP page, you need to get background data, or you want to handle some logic in the background. You can use this method:
1 Background code:
Package com.cd.util;Import java.util.List;Get all Provincespublic class
JAKARTA struts structure porting the PHP development framework, using object-oriented development architecture and APIs, simulates an HTTP servlet container and uses the PHP Service page engine technology.
Download Address:
El expression in jsp
The full name of EL is Expression Language. EL:
Get data:
EL expressions are mainly used to replace the script expressions on JSP pages to retrieve java objects and obtain data from various types of web domains. (An object in a
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.