JSTL-java ee5 tutorial
来源:互联网 发布:上海专业seo公司 编辑:程序博客网 时间:2024/05/17 07:53
JSTL includes a wide variety of tags that fit into discrete functional areas. To reflect this, as well as to give each area its own namespace, JSTL is exposed as multiple tag libraries. The URIs for the libraries are as follows:
- Core:
http://java.sun.com/jsp/jstl/core
- XML:
http://java.sun.com/jsp/jstl/xml
- Internationalization:
http://java.sun.com/jsp/jstl/fmt
- SQL:
http://java.sun.com/jsp/jstl/sql
- Functions:
http://java.sun.com/jsp/jstl/functions
the following table summarizes these functional areas along with the prefixes.
c
x
fmt
sql
fn
Thus, the tutorial references the JSTL core tags in JSP pages by using the following taglib
directive:
<%@ taglib uri="http://java.sun.com/jsp/jstl/core
"
prefix="c" %>
In addition to declaring the tag libraries, tutorial examples access the JSTL API and implementation. In the Application Server, the JSTL TLDs and
libraries are distributed in the archive <
J2EE_HOME
>/lib/appserv-jstl.jar
. This library is automatically loaded into the classpath of all web applications running on the Application Server, so you don't need to add it to your web application.
sql查询语句可以写为:
带参数:
select * from web_bookstore_books where bookId=? <sql:param value="${bid}"/>
</sql:query>
<sql:param value="${bookId}" />
</sql:query>
数据库更新:
<sql:param value="${item.quantity}" />
<sql:param value="${bookId}" />
</sql:update>
注意配置文件:
<res-ref-name>jdbc/BookDB</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
<res-sharing-scope>Shareable</res-sharing-scope>
</resource-ref>
- JSTL-java ee5 tutorial
- java ee5 tutorial - 属性文件
- JSP Documents-java ee5 tutorial
- java ee5 tutorial - bookstore2 MVC实现(dispatcher)
- java ee5 tutorial - 数据库的访问
- jsp中传输中文参数(java ee5 tutorial)
- Java EE5.0
- JAVA EE5 新特性
- 《Java EE5开发指南》读书笔记
- java EE5 与 Email 冲突
- java ee5和java ee6的区别
- EE系统标准(JAVA EE5)
- java ee5中开发web service
- java在线文档(java se6,java ee5)
- Java EE5 and Java EE 6 support for annotations
- 【《Java EE5实用教程:基于WebLogic和Eclipse 》图书目录
- Java EE5 文档:创建自定义验证器(p398-404)
- JRE System Library 与Java EE5 Libraries的区别
- 美女睡觉
- 创新谈-许震
- SAP所有用户出口列表(4.6C)
- 控制2000或者xp系统重新启动、关机
- 蒙人的电视台
- JSTL-java ee5 tutorial
- 建立ADO的详细步骤
- quartz32.dll病毒去除方法
- Thinkpad 的一个该死的驱动程序安装说明
- 1032
- 项目经验-张国义
- 回来!我的爱。
- Java 应用程序默认权限(简例)
- 1051 P,MTHBGWB