HTML Tags: <div> and <span> - Slides
Document Details

Uploaded by PrettyOnyx5971
York University
May Haidar
Tags
Summary
These slides, created by May Haidar at York University, introduce essential HTML tags, focusing on div and span elements. The presentation explores how block and inline elements function within web pages, providing examples and code snippets to illustrate the concepts. The slides cover core topics in web development.
Full Transcript
2.5 HTML Tags: and Block Level Elements ❑ Block level elements are rendered on the page from edge to edge For example: This is a block element in HTML ❑ Some block level elements are: All rights rese...
2.5 HTML Tags: and Block Level Elements ❑ Block level elements are rendered on the page from edge to edge For example: This is a block element in HTML ❑ Some block level elements are: All rights reserved ©May Haidar - York University Inline Elements ❑ Inline elements are embedded by default within a line For example: This is an inline element Some other HTML content in HTML ❑ Some inline elements are: All rights reserved ©May Haidar - York University Block vs. Inline Elements HTML5 Practical categories of content elements: Flow Content ❑ Block Element Displayed as blocks starting on a new line May be nested with other block or inline elements HTML5 Phrasing Content ❑ Inline Elements Displayed on the same line May be nested with only inline elements More complex categorization is introduced in HTML 5 replacing the above definitions All rights reserved ©May Haidar - York University The div element ❑Block Level Configure a specially formatted division or area of a web page ❑Block display with empty space above and below the div ❑Can contain other block display and inline display elements This is a heading in a div element This is some text in a div element All rights reserved ©May Haidar - York University The span element ❑ inline Level Configure a specially formatted text ❑ An inline tag used to mark up a part of a text, or a part of a document. Sally has blue eyes and John has dark green eyes. All rights reserved ©May Haidar - York University Thank You All rights reserved © May Haidar - York University