<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSTL c:remove的使用</title>
</head>
<body bgcolor="#ffffff">
<c:set value="10000" var="maxUser" scope="application"/>
<c:set value="20" var="maxIdelTime" scope="session"/>
<c:set value="hellking" var="accountId" scope="request"/>
<c:set value="next.jsp" var="nextPage" scope="page"/>
在没有调用c:remove之前,有这些参数;
maxUser=<c:out value="${maxUser }"/>
maxIdelTime=<c:out value="${maxIdelTime }"/>
accountId=<c:out value="${accountId }"/>
nextPage=<c:out value="${nextPage }"/>
<hr/>调用c:remove...
<c:remove var="maxUser" scope="application"/>
<c:remove var="maxIdelTime" scope="session"/>
<c:remove var="accountId" scope="request"/>
<c:remove var="nextPage" scope="page"/>
调用了c:remove之后,这些参数值为:
maxUser=<c:out value="${maxUser}"></c:out>
maxIdelTime=<c:out value="${maxIdelTime }"></c:out>
accountId=<c:out value="${accountId }"></c:out>
nextPage=<c:out value="${nextPage }"/>
</body>
</html>