Is a good practice put the <header> tag within the <section> one? I know it's correct within <header>, <article>, <aside>, <footer>.

<section> has used to separate different themes of our page and often we might find <article> within that (perhaps with their <header>). Then my doubt about the correctness of using the <header> tag into the <section>.

for e.g.

<body>
 <header>
  <hgroup>
   <h1>hello</h1>
   <h2>world</h2>
  </hgroup>
 </header>
 <section>
  <header>Total news</header>
  <article>
   <header><h1>News</h1></header>
   <section>
    <header>Daily news</header>
    <article>
     <header><h2>News 1 title</h2></header>
     <p>news 1</p>
    </article>
    <article>
     <header><h2>News 2 title</h2></header>
     <p>news 2</p>
    </article>
   </section>
  </article> 
 </section>
 <section>
  <header><h1>Another section</h1></header>
  <article>
   <p>Content of another section</p>
  </article>
 </section>
 <footer>
  <p>Copyright</p>
 </footer>
</body>

没有正确的解决方案

其他提示

Your first header <header>Total news</header> would be a simple <H1>.

The <header><h1>News</h1></header> would be <hgroup><h1>News</h1></hgroup> (In this example you dont really need that container)

You also should think about your usage of Tags. You don't have to use all of them just because it's the 'correct order'. The less tags you use, the better.

It is perfectly appropriate to put the <head> tag inside a <head> tag and it is even recommended according to this article http://www.anthonycalzadilla.com/2010/08/html5-section-aside-header-nav-footer-elements-not-as-obvious-as-they-sound/. The <article> tag can also be put inside a <section> tag based on this article http://html5doctor.com/the-article-element/.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top