Components
<h2 id="elements">HTML Elements</h2>
- Element
<h2 id="elements">HTML Elements</h2>- Tag
<h2>- Attribute
id- Attribute's value
"elements"- Text content
"HTML Elements"
<h2 id="elements">HTML Elements</h2>
<h2 id="elements">HTML Elements</h2><h2>id"elements""HTML Elements"<header>, <article>, <form>, <nav>, and <table><div> and <span><div><p>, <ul>-<li> and <h1>-<h6><span><code>, <a> and <strong>Check out the CSS Flow layout for normal flow etc.
<html> is the main root and its direct children are <head> where we put metadata and <body> where we put the content. Metadata elements inside <head> are written as direct children. The content elements though, are very flexible and can be super nesting. Below is just an example to give a rough idea.
Keep in mind that many semantic tags are actually from HTML5 in 2008. Before then, there were no <header>, <nav>, <section> and <footer> for example. They are all sectioned inside nesting <div> when needed.
<html>
<head>
<title>...</title>
<meta>
<link>
<base>
<style>...</style>
</head>
<body>
<header>...</header>
<nav>...</nav>
<main>
<section>...</section>
<section>...</section>
<section>...</section>
</main>
<aside>...<aside>
<footer>...</footer>
<script>...</script>
</body>
</html>
In the following sections, elements will be listed by their tags and sectioned based on their functions/roles. Listing will be given in nesting style. Some parent-child relations are rather exact, some are more of an illustration or common example to give a better idea how these element tags are used.
<main><head><body><head><head> element.<title><title>HTML Intro</title><link>rel: relationship. Values example: stylesheet, preconnect.ref: URL<link rel="stylesheet" href="./style.css"><link rel="preconnect" href="https://fonts.googleapis.com"><style>
<style>
p {color: blue}
</style>
<base>href: URL of all the relative links in the page.target: Target page of opening any page link if not specified further.
<head>
<base href="https://duaransel.com/" target="_blank">
</head>
<body>
<img src="img/placeholder.jpg">
<a href="tags/tag_base.asp">HTML base Tag</a>
</body>
<meta><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><address><article><aside><footer><h1>-<h6><header><main><nav>Go to HTML Content Sectioning Elements page
<blockquote><dd><div><dl><dt><figcaption><figure><hr><li><menu><ol><p><pre>Go to HTML Text Content Elements page
<a><abbr><b><bdi><bdo><br><cite><code><data><dfn><em><i><kbd><mark><q><rp><rt><ruby><s><samp><small><span><strong><sub><sup><time><u><var><wbr>Go to HTML Inline Text Semantic Elements page
<img><audio><video><track><map><area><object><param><picture><source> elements and one <img> element to offer alternative versions of an image for different display/device scenarios.<source><picture>, <audio>, or <video> element<embed><iframe><portal><svg><math><math> tags.<script><noscript><canvas><del> and <ins> marking deletion and insertion to the document to track changes.
<del><ins><caption><col><colgroup><table><tbody><td><tfoot><th><thead><tr>Go to HTML Table Elements page
<button><datalist><fieldset><form><input><label><legend><meter><optgroup><output><progress><select><textarea><details><summary>
<details>
<summary>Default display</summary>
Detailed information on default display.
</details>
<details open>
<summary>Open attribute</summary>
Detailed information on open attribute.
</details>
<dialog><slot>slot
<template>Warning: Elements before are deprecated or obsolete. Do not use, and replace if it's in use.
<dir><ul><hgroup><h1>-<h6> directly<center>text-align: centermargin-right: auto and margin-left: auto<nobr>white-space: nowrap<plaintext><pre>, <code>, or CSS font-family with monospace value.<xmp><pre>, <code>, or CSS font-family with monospace value.<tt><code>, <kbd>, <samp>, <var>, <pre>, or <span> styled with CSS font-family<spacer><acronym><abbr><rb> <rtc><ruby> elements<basefont><font><big>font-size: larger<strike><del>, <s>, or CSS styling<content><slot><shadow><image><img><bgsound><audio><applet> <noembed><object><frame> <frameset> <noframes><iframe><blink><marquee><menuitem><keygen>