[whatwg] href on any element

Andrew Fedoniouk news at terrainformatica.com
Mon Aug 28 23:27:51 PDT 2006


----- Original Message ----- 
From: "Lachlan Hunt" <lachlan.hunt at lachy.id.au>
To: "Andrew Fedoniouk" <news at terrainformatica.com>
Cc: "Ian Hickson" <ian at hixie.ch>; "Anne van Kesteren" 
<fora at annevankesteren.nl>; "WHATWG" <whatwg at whatwg.org>
Sent: Monday, August 28, 2006 11:05 PM
Subject: Re: [whatwg] href on any element


> Andrew Fedoniouk wrote:
>> Ian Hickson wrote:
>>>   <a href="">
>>>    <h2>...</h2>
>>>    <p>...</p>
>>>   </a>
>>
>> If we will change model of A from
>> <!ELEMENT A - - (%inline;)* -(A)       -- anchor -->
>> to something else then it will create implications for parser.
>
> What implications?  Changing the formal content model of an element 
> doesn't change the way a parser needs to work.  Ian's example above is 
> very similar to some real world examples I've seen and browser's already 
> handle it just fine.

These are non-conformant browsers :)
A simply cannot have content other than inline constructions.
What UA should do in this case is not specified. Using this
is as bad as violation of following:

"The P element represents a paragraph. It cannot
contain block-level elements (including P itself)."

We all can see that browsers that just ignore this rule. And where are we
now?

>
> The DOM looks like this:
>
> A
> +-H2
> + P
>

And what is semantical meaning of that? Some hyperlinked section?

If yes then let it be just :

<section href="...">
  <h2>...
  <p>...
</section>


Andrew Fedoniouk.
http://terrainformatica.com






More information about the whatwg mailing list