Re: [XHTML2] How are UAs to interpret <h> and <hx> elements?

Laurens Holst wrote:
> I see three solutions:
> 1. just let there be multiple h elements in a section for the body case 
> (but recommend separate sections for the rest),

I'd rather the rules be the same for both body and section.  If we allow 
multiple h elements in the body, then we should do so for section.

> 2. require h elements to be nested in a section and to have only one h 
> element per section,

If that's the case, should <h> be required to be the first child of 
<section>?  If it's not the first child, is it still the heading for any 
content before it?  If so, how do we then handle cases where authors 
insert multiple headings?  How do we handle subtitles?  eg.

<section>
   <h id="logo" src="...">The World Wide Web Consortium (W3C)</h>
   <h id="slogan">Leading the Web to Its Full Potential...</h>
   ...
</section>

Is that a use case for numbered heading elements?

<section>
   <h1 id="logo" src="...">The World Wide Web Consortium (W3C)</h1>
   <h2 id="slogan">Leading the Web to Its Full Potential...</h2>
   ...
</section>

Or, should that really be this?

<section>
   <h id="logo" src="...">The World Wide Web Consortium (W3C)</h>
   <p id="slogan">Leading the Web to Its Full Potential...</p>
   ...
</section>

> 3. or, taking it a little further, replace body entirely by section, or 
> something like that. Which is better than allowing two body elements to 
> be present, because for one that doesn’t make sense, a document has only 
> one body and the separate sections don’t belong to entirely separate 
> ‘bodies’ of the document, and secondly you want a section to be called a 
> section and not anything else (for different kinds of sections, we have 
> @role after all).

If I understand you correctly, does that mean this kind of structure 
could be used for multiple top-level sections?

<html>
   <head/>
   <section/>
   <section/>
   <section/>
</html>

Lastly,
4. Define the top level heading to be body>h, if present, or 
body>section>h otherwise.

That makes these semantically identical:

<body>
   <h>Heading 1</h>
   <section>
     <h>Heading 1.1</h>
   </section>
</body>

<body>
   <section>
     <h>Heading 1</h>
     <section>
       <h>Heading 1.1</h>
     </section>
   </section>
</body>

-- 
Lachlan Hunt
http://lachy.id.au/

Received on Monday, 13 June 2005 01:58:31 UTC