As in:
<header id="mainHeader">
<hgroup>
<h1>Title</h1>
<h2>Sub Title</h2>
</hgroup>
<aside>
<p>Some content within the header but isn't as important.</p>
<p>Some content within the header but isn't as important line 2.</p>
</aside>
</header>
The reason for this, as demonstrated above, is that I have some content that belongs to the header (for instance, a short block of information) but is only somehow related but not really as essential as the h1 and h2 tags.
Or should I just use a normal div?
As per HTML5 drafts, <aside>
is content tangential to the main content, so this is not about importance but about topics. The <aside>
element might contain shocking news, which are tangential to the boring content of a dull page.
What really matters is what other people who might look at your HTML markup think about it. The “semantics” of the new elements like <header>
and <aside>
has recently been characterized (by Hixie, the HTML5 editor) as mostly relating to ease of authoring and maintenance.
If you are not sure of the “semantics” yourself, the odds are that others would have difficulties with it, too. So it might be safer to use just <div class="foo">
where foo
somehow characterizes the role of the content.
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