Block-level label display

One,

HTML tags are generally divided into two block-level tag and the tag line, they are also known as block elements and inline elements.

1, block-level elements (block-level)

Not a block-level elements alone will account for one or more lines may be provided on its width, the width, etc. of its familiar, commonly used in building the page and page layout.

The block elements have common # <h1> ~ <h6> <div> <p> <ol> <ul> <li> etc., wherein <div> is the most typical block element.

*

2, row element (inline-level)

Inline elements (inline elements) not occupy separate areas, only its size and the image size of the font to the support structure, the width is generally not provided, the high point, its other attributes; control line for the text style of the page.

Common elements have expert #: <a>, <strong>, <b>, <em>, <s>, <i>, <del>, <ins>, <u>, <span> etc., wherein < span> tag is the most typical inline elements.

* 1. The composition can only text passages, so p can not be placed inside the block elements, as well as these labels Similarly h1 ~ h6, dt

3, the row block elements (inline-block)

Second, the display mode transits

 

Guess you like

Origin www.cnblogs.com/rjl888/p/11415287.html