<article>
The <article>
element is used to encapsulate a self-contained piece of content, such as a news article, blog post, or forum post. It should make sense on its own and be able to be distributed independently.
<article>
<h2>Introducing HTML5 Semantic Elements</h2>
<p>HTML5 semantic elements are designed to...</p>
</article>
<aside>
<aside>
is used for content that is tangentially related to the main content but can be considered separate, such as sidebars, pull quotes, or advertisements.
<article>
<h2>Exploring HTML5 Elements</h2>
<p>...</p>
<aside>
<h3>Related Articles</h3>
<ul>
<li><a href="#">Understanding HTML5 Semantics</a></li>
<li><a href="#">Mastering CSS Grid</a></li>
</ul>
</aside>
</article>
<figcaption>
and <figure>
<figcaption>
and <figure>
work together to associate a caption with an image or other media content, enhancing accessibility and providing context.
<figure>
<img src="image.jpg" alt="A beautiful landscape">
<figcaption>Scenic view of a serene landscape.</figcaption>
</figure>
<footer>
The <footer>
element represents the footer of a section or page, typically containing copyright information, contact details, and related links.
<footer>
<p>© 2023 MyWebsite</p>
<nav>
<ul>
<li><a href="#">Privacy Policy</a></li>
<li><a href="#">Contact Us</a></li>
</ul>
</nav>
</footer>
<header>
<header>
represents the header of a section or page, often containing logos, headings, and navigation menus.
<header>
<h1>Welcome to My Website</h1>
<nav>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Services</a></li>
</ul>
</nav>
</header>
<mark>
The <mark>
element highlights or marks text for reference or emphasis.
<p>Important dates:<mark> October 24, 2023</mark> and <mark>November 10, 2023</mark></p>
<nav>
<nav>
is used to define navigation menus or links within a page or site.
<nav>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Services</a></li>
</ul>
</nav>
<progress>
The <progress>
element represents the completion progress of a task, such as a file upload or a form submission.
<progress value="70" max="100"></progress>
<section>
<section>
defines a thematic grouping of content within a document, such as chapters, subsections, or parts of an article.
<section>
<h2>Section 1: Introduction</h2>
<p>...</p>
</section>
<section>
<h2>Section 2: Features</h2>
<p>...</p>
</section>
<summary>
The <summary>
element is used in conjunction with the <details>
element to provide a summary or heading for a collapsible content section.
<details>
<summary>Click to expand</summary>
<p>Hidden content goes here...</p>
</details>
<time>
<time>
represents a specific point in time or a range of time. It helps machines and search engines understand dates and times on the page.
<p>Event date: <time datetime="2023-09-30T18:30:00">September 30, 2023, 6:30 PM</time></p>
Comments
Post a Comment