c_remove.jsp

来自「jsp开发详解第15章全部代码」· JSP 代码 · 共 29 行

JSP
29
字号
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
<%@ page contentType="text/html; charset=gb2312" language="java" %>
<html>
<head>
  <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:rmeove之前,有这些参数:
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}"/>,
maxIdelTime=<c:out value="${maxIdelTime}"/>,
accountId=<c:out value="${accountId}"/>,
nextPage=<c:out value="${nextPage}"/>,
</body>
</html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?