@@Gunnar Bittersmann
<p><i a><p>
generiert im DOM dasselbe wie
<p><i a=""></i></p><p><i a=""></i></p>
Da das
i
im erstenp
nicht geschlossen wurde, wird es im zweiten fortgesetzt, d.h. auch eini
mit denselben Attributen im zweitenp
generiert.
Ich bin da mal mit Tests in die Tiefe gegangen:
<p><i a><b b><p>
<p><i a=""><b b=""></b></i></p><p><i a=""><b b=""></b></i></p>
Auch Kinder werden mit kopiert.
<p><i a><a b><a c><p>
<p><i a=""><a b=""></a><a c=""></a></i></p><p><i a=""><a c=""></a></i></p>
Aber nicht alle.
(a
werden natürlich nicht verschachtelt, sondern bilden Geschwisterelemente – wie auch p
.)
<p><i a><c b><p>
<p><i a=""><c b=""></b></i></p><p><i a=""></i></p>
Unbekannte schon gar nicht.
Hier hätte ich gedacht, dass c
sich genauso verhält wie span
. Weit gefehlt.
😷 LLAP
--
“When I was 5 years old, my mother always told me that happiness was the key to life. When I went to school, they asked me what I wanted to be when I grew up. I wrote down ‘happy.’ They told me I didn’t understand the assignment, and I told them they didn’t understand life.” —John Lennon
“When I was 5 years old, my mother always told me that happiness was the key to life. When I went to school, they asked me what I wanted to be when I grew up. I wrote down ‘happy.’ They told me I didn’t understand the assignment, and I told them they didn’t understand life.” —John Lennon