introduceHTML provides the contextual structure and meaning of the content of a web document; HTML itself has no expression. For example, we see that <H3> is bold and the font size is 2em; <strong> is bold, but don’t think that these are the expression of HTML. This is the default style of HTML at work. So we need to know that HTML has nothing to do with the expression of the page . Expression is the business of CSS. The role of HTML in a page is structure and meaning. To put it simply, it is to divide the content. What is put here is what we put. StructuringIf a web page is compared to a house, then HTML is the reinforced concrete walls and the roof and beam frames; and CSS is the decorative materials, floor paint and the like. A good page structure means that even without CSS decoration, the page structure is still clear and the house is still visible. The DIV+CSS that people often talk about is just a popular term, not DIV throughout the article. Remember: DIV is not God! SemanticHTML is a supplementary representation of the content and meaning (i.e. semantics) of text. It tells us, "This line is a heading, these lines form a paragraph, this is a bulleted list, that is a link." It doesn't tell us, "These words are blue, those are red, this part is on the right, these are italic." That's the job of CSS. In short: HTML tells us what a piece of content is (or what it means), not what it looks like. Copy code The code is as follows:<!--Unsemanticized--> <div id="header"> <div class="H3">Former Brick Siege Master</div> <div class="h2">Building with blocks is also about art</div> </div> <!--After semanticization--> <div id="header"> <H3>Former Brick Siege Master</H3> <h2>Building with blocks is also about art</h2> </div> What are the benefits of semantics?
Appendix: New elements in HTML5
|
<<: Teach you how to use Portainer to manage multiple Docker container environments
>>: Sample code for making a drop-down menu using pure CSS
I believe that many friends who are new to web pag...
Environmental Description Server system: Ubuntu 1...
I've been using redis recently and I find it ...
This article shares the specific code of jQuery t...
What is Redis Cluster Redis cluster is a distribu...
Recently the company has arranged to do some CCFA...
The core is mysqldump and Runtime The operation i...
Look at the code first Copy code The code is as fo...
There was no problem connecting to the database y...
MySQL 5.7.20 installation and configuration metho...
Array Methods JavaScript has provided many array ...
The question is referenced from: https://www.zhih...
Table of contents 1. Basic knowledge: 2. DHCP ser...
I am going to review Java these two days, so I wr...
1. Introduction pt-query-digest is a tool for ana...