1. HTML elements with no content are called empty elements. The empty element is closed in the Start tab. Adding slashes to the start tag, such as <br/>, is the correct way to close an empty element, which is accepted by HTML, XHTML, and XML. Even if <br> is valid in all browsers, the use of <br/> is actually a longer term guarantee.
2.HTML label is case insensitive:<p> is equivalent to <p>. Many websites use uppercase HTML tags. W3cschool uses lowercase tags because the World Wide Web Consortium recommends lowercase in HTML 4, and lowercase in future (X) HTML versions.
3.HTML attribute instances: HTML links are defined by <a> tags. The address of the link is specified in the href attribute : <a href= "http://www.w3cschool.cc" >this is a link</a>. Attribute values use single and double quotes, but in some cases, such as the attribute value itself contains double quotes, you must use single quotes , for example: Name= ' John ' shotgun ' Nelson '. Property and property values are still recommended for lowercase.
4. Title is important
Make sure that the HTML caption label is used for headings only. Don't use headings just to create bold or large text. search engines use headings to index the structure and content of your Web pages . Because users can quickly navigate through your pages with headings, it is important to use headings to present the structure of the document. H1 should be used as the main title (most important), followed by H2 (minor), followed by H3, and so on.
5.HTML Output-Use reminders
We cannot determine the exact effect of HTML being displayed. The size of the screen, as well as the adjustment of the window, can result in different results. For HTML, you cannot change the effect of the output by adding extra spaces or line breaks in the HTML code. When a page is displayed, the browser removes extra spaces and blank lines from the source code. All contiguous spaces or blank lines are counted as a single space. Note that all consecutive empty lines (line breaks) in the HTML code are also displayed as a single space.
HTML element Summary
|
Defining HTML Documents |
<body></body> |
Defining the body of a document |
|
Define HTML headings for search engines |
|
Define horizontal lines |
<!--......--> |
Defining annotations |
<p></p> |
Defining paragraphs |
<br/> |
newline character, inserting a line break |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Review the contents of the previously learned html+css