[whatwg] Update to the Adoption Agency Algorithm

Lachlan Hunt lachlan.hunt at lachy.id.au
Fri Feb 3 13:06:27 PST 2006


Blanchard, Todd wrote:
>> Any markup that causes a browser to automatically clone a node will 
>> be non-conformant and will be flagged as erroneous by a validator.
> 
> You are assuming that validators run javascript - they generally 
> don't.

I'm well aware that validators don't run JavaScript and I'm talking 
about a case where they don't even need to.  Given this markup that will 
cause a node to be cloned by the Adoption Agency Algorithm:

<em id="x"><p>foo</em>bar</p>

The validator *will* flag that as an error and, according to the 
algorithm, it will also cause duplicate IDs, which is what we were 
discussing.

The only case that won't happen is if that markup is written as a result 
of document.write() or innerHTML.

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




More information about the whatwg mailing list