Home > Web Front-end > HTML Tutorial > In HTML5, how do we display the main content of the document?

In HTML5, how do we display the main content of the document?

PHPz
Release: 2023-08-26 23:33:02
forward
678 people have browsed it

In HTML5, how do we display the main content of the document?

HTML

Markup specifies the main or important content in the document. It can only be used once per page, and cannot be used as a descendant of
,

Example

You can try running the following code to understand how to display the main content in an HTML document -

<!DOCTYPE html>
<html>
   <body>
      <main>
         <h1>Learning</h1>
         <p>Learn to gain experience and try to share your knowledge with others.</p>

         <article>
            <h3>Web Development Tutorials</h3>
            <p>Consist of CSS, HTML, and PHP tutorials for 2nd Semester exams.</p>
         </article>

         <article>
            <h3>Academic Tutorials</h3>
            <p>Consist of Computer Fundamental, Computer Network tutorials for 1st Semester exams.</p>
         </article>
      </main>
   </body>
</html>
Copy after login

The above is the detailed content of In HTML5, how do we display the main content of the document?. For more information, please follow other related articles on the PHP Chinese website!

source:tutorialspoint.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template