Block elements, inline elements, the line difference block

A block-level elements:

1. Always start a new line.

2. The controllable width and height. (Margin, padding can be set)

3. When the width and height is not provided, the default is 100%.

4 may comprise a block element and an inner row elements.

The block-level text element can not be placed in the other block-level elements.

6. mostly structure tags.

Second, inline elements:

1. and other elements in a row.

2. The height, width, and upper and lower margins are not controllable.

3. The width and height is the height of content, relying on its own font sizes and graphics support structure, can not be changed.

4. inline element within the element rows can not contain block-level elements.

5. paddding around the element row may be provided.

6.margin only horizontal margins can be set, namely: margin-left and margin-right, and the set margin-top margin-bottom invalid.

7. mostly structural markup block level.

Third, the row block-level elements:

Integrated level elements and inline elements characteristic block, width and height can be set (default content width and height) may be provided inside and outside margins.

Guess you like

Origin www.cnblogs.com/superman-z/p/11525207.html