coping with overlapping elements in the DOM

One of the big problems in trying to come up with a reasonable 
specification for the DOM is trying to figure out how much we
should do to cope with broken HTML documents. Obviously
seriously broken documents will cause so many problems
that we just don't want to get into, but there are some 
classes of common mistakes that we can maybe allow.

One of these classes of mistakes is overlapping elements, 
of the form
<P><B>This is <EM> not </B> a good idea</EM></P>

We are thinking of defining nodes that would effectively change
the above example into
<P><B>This is <EM> not </EM></B><EM> a good idea</EM></P>

This does have effects on style sheets and other operations that
refer to the parent element, since the first EM element has a 
different parent in the two examples.

Since we don't really want to encourage people to write broken 
documents, there is also the problem of whether we should do 
anything for overlapping elements at all. The choices are:
1) don't do anything for overlapping elements
2) do something and deprecate it immediately, so it will be in level 
one but not level two
3) put it in without deprecating.

The DOM WG would like feedback on this issue. Which option do
you think the best?

thanks,

Lauren

--

Lauren Wood, posting as chair of the W3C DOM WG

Received on Tuesday, 5 August 1997 18:45:20 UTC