HTTP — Hypertext Markup Language. The markup for creating webpages/documents.
Tags(angle brackets) surround the elements. Some tags close themselves(Remnant of XHTML)
DOCTYPE: Instruction to web browser what type + version of markup language(HTML) is used in the current page. It is not a tag or element. Also, it’s not case sensitive. Interpreter inside the web browser understands the markup using doctype and effectively renders the view. Various types available are HTML5, HTML4, XHTML,…
<!DOCTYPE html> // Specifies html5
Head Tag contains metadata about that page.
<head>
<meta charset="UTF-8"> // specifies character encoding
<meta name="viewport" content="width=device-width, initial-scale=1.0"> // responsive design
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
Semantic elements clearly defined the objective by its name so increase the readability of the code.
Semantic Elements: header, article, footer, form, table
**Non Semantic Elements: **div, span,
According to the W3C: “A semantic Web allows data to be shared and reused across applications, enterprises, and communities.”
HTML5 introduced some new Semantic elements like header, nav, section(content with header), aside(content that can be set aside), article(which give information independent info), footer.
HTML5 semantic elements also help search engines to read the page and find the required information faster. (SEO Friendly)
Some other commonly use semantic tags are figure(used with figcaption and img), time,
Two ways of adding Js in HTML:
Placing scripts at the bottom of the element improves the display speed because script interpretation slows down the display.
#semanticweb #html #async #html5-development #defer