Home >Web Front-end >HTML Tutorial >html: What does the nav tag actually do?
I searched for this tag on the Internet to define the link part of Navigation, but I didn’t see any impact even if I removed it. I think I haven’t reached the point where it is useful yet. Please tell me what unique function it has? In addition, when learning HTML, I want to see the unique functions of each tag, but I often feel that some tags are useless, some cannot be seen from the effect, or the tags have similar functions, how can I remove them? What about discernment and experience?
is just a tag used to enhance semantics in html5. Semantic is beneficial to the SEO of web pages.
Just for semantics. May be helpful for seo. Similar to p, h1, font, but some tag browsers add default styles.
html just defines the structure or meaning of the web page, and the specific performance effect is the task of css.
So about c787b9a589a3ece771e842a6176cf8e9 you only need to know that it is only navigation in the sense
Hello, it is similar to header and footer. It is just for people to easily identify the document structure. There is no special style on css.
This is the new tag in html5:
<nav><a>首页</a><a>文章</a><a>关于</a></nav>The usage is the same as writing with div before:
<div class="nav"><a>首页</a><a>文章</a><a>关于</a></div>It’s just that using nav is more conducive to code reading and It is a common thing in web pages, and it increases the semantics of HTMLhtml5. A semantic tag added by itself Semantic tags are highly readable, easy to encapsulate and maintain, and are also beneficial to seo
The above is the detailed content of html: What does the nav tag actually do?. For more information, please follow other related articles on the PHP Chinese website!