This article mainly introduces the usage of horizontal line annotation and code annotation in HTML. It is the basic knowledge in HTML beginners. For more information, see
Horizontal line
Use The label draws a horizontal split line at the current position.
Example:
Copy XML/HTML Code to clipboard
Main Content
-
Bottom content
The horizontal line can effectively isolate different content and give a sense of attention.
Tip:
Because CSS can be used to format and display the boundaries of divs or other block elements (border), the width of the boundary of block elements is often set to achieve the effect of a horizontal line.
Tags cannot be completely replaced.
HTML comment
The XHTML annotation label is a special label. As the name suggests, it is used to comment the content in the XHTML document. Of course, it will not be displayed in the browser. The annotation label is as follows:
Copy XML/HTML Code to clipboard
-
- Example:
Note:
There is an exclamation point behind the left bracket at the beginning. Do not write comments in other languages such as "//" or.
Tip:
Adding a comment as appropriate is a good habit. It can be used wherever you want to comment, so that the html document we write is easy to read and maintain.