HTML5 Article Element Tutorial
In this page, we have discussed Description, Usage, Attributes, Example, Result, and Compatibility of HTML5 article element.
The HTML Article element (<article>) represents independent (w.r.t a web document, page, site or application) content, for example a forum post, a magazine or newspaper article, a blog entry, a user-submitted comment, an interactive widget or gadget.
The HTML Article Element contains either actual content or contains several different section elements or one or more article elements within it.
If it contains article element within it, the content of the inner articles supposed to be related to the outer article's content.
If it is necessary to provide author information of the article, that can be done using <address>.
Using pubdate attribute of time element, date and time of publication of an article can be described.
<article> <h1>Tutorial of HTML5 article element</h1> <p>HTML5 article element represents independent item like a blog entry in an web document.</p> </article>
Whether start and end tag are required
Both start and end tag are required.
What an article element can contain
Text or embedded content.
Which elements can contain article element
Any element except the elements which can contain text or embedded content.
article element does not have any other attributes than the global attributes (accesskey, class, contenteditable, contextmenu, dir, draggable, dropzone, hidden, id, lang, spellcheck, style. tabindex, title), common to all elements.
<!DOCTYPE HTML> <html lang="en"> <head> <meta charset=utf-8> <title>HTML5 article example</title> </head> <body> <article> <h1>Tutorial of HTML5 article element</h1> <p>HTML5 article element represents independent item like a blog entry in an web document.</p> </article> </body> </html>
We have successfully tested the above example with following browser versions.
|Feature||Chrome||Firefox (Gecko)||Internet Explorer||Opera||Safari|
Test your Programming skills with w3resource's quiz.
- Weekly Trends
- Python Interview Questions and Answers: Comprehensive Guide
- Scala Exercises, Practice, Solution
- Kotlin Exercises practice with solution
- MongoDB Exercises, Practice, Solution
- SQL Exercises, Practice, Solution - JOINS
- Java Basic Programming Exercises
- SQL Subqueries
- Adventureworks Database Exercises
- C# Sharp Basic Exercises
- SQL COUNT() with distinct
- Java Collection Exercises
- SQL COUNT() function
- SQL Inner Join