🔧 ProgrammierungWhat If AI Had a Digital Endocrine System?(16.09.2026 um 03:15 Uhr)
🔧 ProgrammierungMy AWS Learning Journey: CloudWatch, Lambda, IAM & CloudFront(16.09.2026 um 03:17 Uhr)
🔧 AI Nachrichten Flint: Turning Skills into Personal Assets(16.09.2026 um 03:17 Uhr)
🔧 ProgrammierungAWS Rhyming Game Contest – Exploring Amazon Kinesis(16.09.2026 um 03:22 Uhr)
🔧 ProgrammierungChandra Meets CodeDeploy: My First AWS Deployment Journey(16.09.2026 um 03:30 Uhr)
📰 IT Security NachrichtenHow A.I. Risks Are Splitting Silicon Valley and Washington(16.09.2026 um 03:24 Uhr)
🔧 ProgrammierungWhat If AI Had a Digital Endocrine System?(16.09.2026 um 03:15 Uhr)
🔧 ProgrammierungMy AWS Learning Journey: CloudWatch, Lambda, IAM & CloudFront(16.09.2026 um 03:17 Uhr)
🔧 AI Nachrichten Flint: Turning Skills into Personal Assets(16.09.2026 um 03:17 Uhr)
🔧 ProgrammierungAWS Rhyming Game Contest – Exploring Amazon Kinesis(16.09.2026 um 03:22 Uhr)
🔧 ProgrammierungChandra Meets CodeDeploy: My First AWS Deployment Journey(16.09.2026 um 03:30 Uhr)
📰 IT Security NachrichtenHow A.I. Risks Are Splitting Silicon Valley and Washington(16.09.2026 um 03:24 Uhr)

🔧 Programmierung 🕛 vor 2 Jahren 4 Min Lesezeit
0

HTML Semantic Elements(A to Z)

↗ Quelle (dev.to)
🗣️ Stimme:
📑 Inhaltsübersicht




HTML Semantic Elements: A Comprehensive Guide



HTML semantic elements clearly describe their meaning in a way that both the browser and the developer can understand. They enhance the readability and accessibility of web pages. This guide explores various semantic elements, their purposes, and practical code examples.






What Are Semantic Elements?



Semantic elements are HTML elements that convey meaning about the content they contain. Unlike non-semantic elements like <div> and <span>, semantic elements provide a clear structure to the web page.






Common HTML Semantic Elements





  1. <header>: Defines a header for a document or a section.


  2. <nav>: Defines a container for navigation links.


  3. <article>: Represents a self-contained piece of content.


  4. <section>: Defines a section in a document.


  5. <aside>: Defines content aside from the content it is placed in.


  6. <footer>: Defines a footer for a document or a section.


  7. <main>: Specifies the main content of a document.


  8. <figure>: Specifies self-contained content, like illustrations or diagrams.


  9. <figcaption>: Provides a caption for a <figure> element.


  10. <time>: Represents a specific time or date.






Example: Using Semantic Elements



Let's create a simple webpage using semantic elements to demonstrate their usage.



HTML Code:




CODE
<!DOCTYPE html>
<html>
<head>
<title>Semantic HTML Example</title>
</head>
<body>
<header>
<h1>Welcome to My Website</h1>
<nav>
<ul>
<li><a href="#home">Home</a></li>
<li><a href="#about">About</a></li>
<li><a href="#contact">Contact</a></li>
</ul>
</nav>
</header>

<main>
<section id="home">
<h2>Home</h2>
<p>This is the home section of the webpage.</p>
</section>

<section id="about">
<h2>About</h2>
<article>
<h3>About Us</h3>
<p>We are a company that values excellence and innovation.</p>
</article>
</section>

<section id="contact">
<h2>Contact</h2>
<aside>
<h3>Contact Information</h3>
<p>Email: [email protected]</p>
<p>Phone: 123-456-7890</p>
</aside>
</section>
</main>

<footer>
<p>&copy; 2024 My Website. All rights reserved.</p>
</footer>
</body>
</html>






Output:



Welcome to My Website




  • Home

  • About

  • Contact



Home

This is the home section of the webpage.



About

About Us

We are a company that values excellence and innovation.



Contact

Contact Information

Email:

Vollständiger Original-Artikel
Den kompletten Beitrag mit allen Details direkt auf dev.to lesen.
↗ Original-Artikel auf dev.to lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 0%
🟡 In Evaluierung 0%
🟢 Keine Auswirkung 0%
Spannende Innovation 0%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
1 Quelle
What If AI Had a Digital Endocrine System?
1 Quelle
My AWS Learning Journey: CloudWatch, Lambda, IAM & CloudFront
1 Quelle
Flint: Turning Skills into Personal Assets
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten HTML Semantic Elements(A to Z)

Thematisch verwandte Begriffe: HTML, Semantic, ElementsA · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...