I understand you can have multiple headers/footers in a page such as for the <article>
s and another site wide header/footer for the <body>
but I've not found anywhere stating that having multiple headers and or footers in a single section is acceptable.
<body>
<header class="header-group-1"></header>
<header class="header-group-2"></header>
<!-- other content -->
<footer class="footer-group-1></footer>
<footer class="footer-group-2></footer>
</body>
Multiple header
elements are allowed, and each of them specifies “introductory content for its nearest ancestor sectioning content or sectioning root element”, i.e. the nearest enclosing article, aside, nav, section, blockquote, body, details, dialog, fieldset, figure, or td element. So you can have e.g.
<body>
<header>body header</header>
...
<article>
<header>article header</header>
...
</article>
There is no prohibition against having e.g. two header
elements (at the same level of nesting) in an article
element. They would then both contain “introductory content” for it. It is however difficult to imagine situations where this would make sense, since header
elements normally precede other content, and the header
would thus be adjacent and could be combined into one.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With