BBS水木清华站∶精华区
发信人: agents (智能代理), 信区: Java
标 题: JSP语法(2)
发信站: BBS 水木清华站 (Tue Jan 2 14:45:36 2001)
2 【Hidden Comment】
Documents the JSP page but is not sent to the client.
▲ [JSP Syntax]
<%-- comment --%>
▲[Examples]
<%@ page language="java" %>
<html>
<head><title>A Comment Test</title></head>
<body>
<h2>A Test of Comments</h2>
<%-- This comment will not be visible in the page source --%>
</body>
</html>
▲[Description]
The JSP engine ignores a hidden comment, and does not process any code
within hidden comment tags. A hidden comment is not sent to the client,
either in the displayed JSP page or the HTML page source. The hidden
comment is useful when you want to hide or "comment out" part of your
JSP page.
You can use any characters in the body of the comment except the closing
--%> combination. If you need to use --%> in your comment, you can escape
it by typing --%\>.
--
※ 修改:·agents 於 Jan 2 15:09:15 修改本文·[FROM: 166.111.54.22]
※ 来源:·BBS 水木清华站 smth.org·[FROM: 166.111.54.22]
BBS水木清华站∶精华区