# HTML Blocks
● HTML Block and Inline Elements
Every HTML element has a default display value depending on what type of element it is.
The default display value for most elements is block or inline.
● Block - Level Elements
A block-level element always starts on a new line and takes up the full width available.
● Inline Elements
An inline element does not start on a new line and only takes up as much width as necessary.
● The <div> Element
The <div> element is often used as a container for other HTML elements. It has no required attributes, but both style and class are common.
When used together with CSS, The <div> element can be used to style blocks of content.
● The <span> Element
The <span> element is often used as a container for some text. this element has no required attribute, but both style and class are common.
When used together with CSS, the <span> element can be used to style parts of the text.
When used together with CSS, the <span> element can be used to style parts of the text.
● HTML Grouping Tags
<div> tag defines a section in a document (block-level).
<span> tag defines a section in a document (Inline).
<span> tag defines a section in a document (Inline).
No comments:
Post a Comment