Google News
logo
HTML5 Main Tag
The <main> Element is an alternative solution for the wrapper or container. The main document on a website can be written under MAIN Element. This Element is allowed once in an HTML5 Document and can't be used as child elements.
Example :
<!DOCTYPE html>
<html>
     
    <head>
         <title>Main Tag</title>
    </head>
     
    <body>
         
        <header>
            <h3>This is Header Part</h3>
        </header>
         
        <main>
            <h4>This is main part</h4>
            <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, </p>
        </main>
         
        <footer>
            <p>This is Footer Part</>
        </footer>
         
    </body>
     
</html>
Output :

This is Header Part

This is main part

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s,

This is Footer Part