Learn HTML5 - Part 2

Опубликовано: 04 Март 2025
на канале: WEBoLOGY. in
40
3

Presented by: Aakash Biswas

Duration: 25.46 minutes

Watch HTML 5 Part 1:    • Learn HTML 5  - Part 1  

The DOCTYPE declaration for HTML5 is:
!DOCTYPE html

The character encoding or charset declaration is:
meta charset="UTF-8"

Semantic Elements
A semantic element describes its meaning to both the browser and the developer.
Non-semantic elements are div and span which tells nothing about its content.
Semantic elements like p, h1, table,form,article etc. Clearly defines its content.

Semantic Elements in HTML5
HTML5 has new semantic elements which defines the different parts of a web page:  

1. article
2. aside
3. details
4. figcaption
5. figure
6. footer
7. header
8. main
9. mark
10. nav
11. section
12. summary
13. time

The article element specifies independent, self-contained content. It is used in:

Forum post
Blog post
Newspaper article


The header element specifies a header for a document or section.
The header element should be used as a container for introductory content.

The footer element specifies a footer for a document or section.
A footer element should contain information about its containing element.
A footer typically contains the ownership info, copyright info, links to terms of use, contact information, etc.

The nav element defines a set of navigation links.
The aside element defines some content aside from the content it is placed in like a sidebar.

The Canvas Element
The canvas element is used to draw graphics using JavaScript.
The canvas element is only a container for graphics. You should use JS to draw the graphics.
Canvas has several methods for drawing paths, boxes, circles, text, and adding images.

The SVG Element
SVG stands for Scalable Vector Graphics
SVG is used to define graphics for the Web
The svg element is a container for SVG graphics.
SVG has several methods for drawing paths, boxes, circles, text, and graphic images.