JSTL Core Tags: Celsina Bignoli
JSTL Core Tags: Celsina Bignoli
Core Tags
Celsina Bignoli
[email protected]
What is a Custom Tag Library?
<%@taglib prefix=“c”
uri=“http://java.sun.com/jsp/jstl/core” %>
• The syntax:
<prefix:action-name attr1=“value1”
attr2=“value2”>
action_body
</prefix:action-name>
• or (with no body)
<prefix: action-name attr1=“value1”
attr2=“value2” />
The Standard Tag Library Core
<c:catch> <c:out>
<c:choose> <c:param>
<c:forEach> <c:redirect>
<c:forTokens> <c:remove>
<c:if> <c:set>
<c:import> <c:url>
<c:otherwise> <c:when>
<c:catch>
• Syntax 2:
<c:set value=“expression” var=“var” scope=“page|
request|session|application” />
<c:url>