Quote:
Originally Posted by Perkin
I also meant to say regarding the non self-closing tags.
IIRC A lot of the elif's were to reduce length of processing time in pairing routine, be removing a lot of the elements needed to check, those (HR BR IMG) as you say should be self closing
|
Should be, yes, but XHTML does not force them to be; the <hr></hr> construction is exactly as valid as <hr/>, even though the latter is the preferred form.
Quote:
Originally Posted by Perkin
One way to change it to not catch them would be add a 1 and a space to each of the tests...
|
Not valid; all three of those elements can (and commonly do) have attributes, which would match the new test.
Quote:
Originally Posted by Perkin
Edit: But the elif with the '/>' would be catching them anyway.
|
That's why I just completely commented out the HR/BR/IMG test. It'd be nice to convert 'em to self-closing, but not touching them is preferable to breaking them.