Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In HTML5, is the <form> element a sectioning element, like <section>?

Tags:

html

forms

In HTML5, some elements (like <section> and <article>) create a new sectioning context in the document‘s outline, as per the outlining algorithm.

This basically means that you can use <h1> as the top-level heading inside them without screwing up the document’s generated outline.

Does the <form> element create a sectioning context?

like image 442
Paul D. Waite Avatar asked Oct 07 '10 00:10

Paul D. Waite


People also ask

What are sectioning elements in HTML?

In HTML, a section is a semantic element for creating standalone sections in a web page. These sections should be made up of related content, like contact information. The section element should only be used if there isn't a more specific element to represent the related content.

Which is not sectioning elements in HTML?

The footer element is not sectioning content; it doesn't introduce a new section. Here is an example which shows the footer element being used both for a site-wide footer and for a section footer.

Is HTML5 a section tag?

<section> is a new HTML 5 element that defines an important section of a document. It can be used within articles, in the header or footer, or to define navigation.

Which element in HTML5 is represent different section in web page?

The <section> HTML element represents a generic standalone section of a document, which doesn't have a more specific semantic element to represent it.


1 Answers

No, because it’s not sectioning content. Only the following elements are sectioning content:

  • <article>
  • <aside>
  • <nav>
  • <section>

However, the <fieldset> element is a sectioning root. This means that it creates a new sectioning context (like a sectioning content element), but headings and sections within it don’t contribute to the outlines of their ancestors.

So you can blindly use <h1> inside a <fieldset> element without screwing up your document’s outline.

Sectioning roots are:

  • <blockquote>
  • <body>
  • <details>
  • <dialog>
  • <fieldset>
  • <figure>
  • <td>

See http://dev.w3.org/html5/spec/Overview.html#headings-and-sections for a full description and examples.

like image 66
Paul D. Waite Avatar answered Sep 20 '22 13:09

Paul D. Waite