标签:items el表达式 stl cas 表达式 tostring 字符串 color for
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
${"abc".concat("123")}
<c:forEach items="${fn:split(‘1,2,3‘, ‘,‘)}" var="str"></c:forEach>
${fn:length("abc")}
${fn:length(fn:split("a,b,c", ","))}
${fn:substring("abc", 0, fn:length("abc"))}
${fn:contains("abc", "a")} (containsIgnoreCase)
不能用于数组、集合(用于数组、集合时,会用对象toString后的字符串来执行,显然不准确)
${fn:replace("abbc", "b", "B")}
标签:items el表达式 stl cas 表达式 tostring 字符串 color for
原文地址:http://www.cnblogs.com/liaolongjun/p/6061653.html