Home  >  Article  >  Web Front-end  >  Nesting rules for Html tags_html/css_WEB-ITnose

Nesting rules for Html tags_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:40:531203browse

1. HTML tags include block-level elements (block) and inline elements (inline)

  1. Block-level elements

Generally used to build website architecture, layout, and content... It includes the following tags:

address、blockquote、center、dir、div、dl、dt、dd、fieldset、form、h1~h6、hr、isindex、menu、noframes、noscript、ol、p、pre、table、ul

2 , Inline elements

Generally used in certain details or parts of website content to "emphasize, distinguish styles, superscripts, subscripts, anchor points", etc. The following tags They are all inline elements:

a、abbr、acronym、b、bdo、big、br、cite、code、dfn、em、font、i、img、input、kbd、label、q、s、samp、select、small、span、strike、strong、sub、sup、textarea、tt、u、var
2. Nesting rules of HTML tags
1. Block-level elements cannot be placed inside

:

<p><ol><li></li></ol></p> ?? 错<p><div></div></p> ?? 错

                                                                                                                                                                                 Level elements, these special tags are:                                                                                                                                                                          🎜>

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn