[xml] HTMLparser: comments in <style> element



Hi,

Currently the HTML parser seems to incorrectly parse comments in the <style> element. For example:

<style>
<!--
h1 { color: red }
-->
</style>

Because this is HTML not XML and the <style> element is CDATA not PCDATA the <!-- should be treated as text, not as the beginning of a comment. However, the HTML parser seems to treat it as an actual comment. Surprisingly, the HTML parser does not treat &amp; as an entity reference, so it does seem to be partially treating <style> as CDATA.

Best regards,

Michael

--
Print XML with Prince!
http://www.princexml.com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]