HTML TutorialLesson 21Free preview
HTML Block & Inline
This lesson is part of HTML · All levels
Summary
HTML elements can be grouped into block-levels that occupy full width such as <div> and <p>, as well as inlines that only wrap up part of the text such as <span> and <a>. The inline elements flow with the surrounding text without starting a new line. This understanding is important when organizing page layouts.
Key points
- Block-level always starts at the new line and meets the width available
- Inline follows the text stream and does not break the line
- Example of block: <div>, <p>, <h1>, <table>
- Inline example: <span>, <a>, <strong>, <img>
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.