JSP Comment method

Source: Internet
Author: User
Tags html comment

Comment method for 1,html

<!--... add your comments here...-->

Description: Use this annotation method, where the comment content is invisible in client browsing. However, when viewing the source code, the customer is
You can see these comment content

2,jsp Comment Tags

The JSP also provides its own markup for comments, which are used in the following format:
Add your comments here
Description: The content of this annotation method is not visible in the client source code, so security is relatively high.

Using annotations in 3,jsp scripts
As already described, the script is the program code embedded between the <% and%> tags, and the script uses the language for Java, the
The comments in the script are the same as the annotation methods in the Java class. You can use "//" to annotate a line, using "/* and * *" to note
Release multiple lines of content. The specific use format is as follows:
Java Code
Single-line Comment
Java Code
/* Multiline Comment
Multi-line Comment */
Java Code

JSP instance:

<!--this is an HTML comment (visible in the client source code)-->
<%--This is a JSP tag comment (not visible in the client source code)
/* Here is the JSP script section,
uses the Java language to implement the string output */
Out.println ("This is an annotation instance");
Print out the string

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

11.11 Big Sale for Cloud

Get Unbeatable Offers with up to 90% Off,Oct.24-Nov.13 (UTC+8)

Get It Now >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.