<[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]

> Python 2.3.5 seems to choke when trying to parse html files, because it
> doesn't realize that what's inside <!--      --> is a comment in HTML,
> even if this comment is inside <script> </script>, especially if it's a
> comment inside that script code too.

Actually, you are technically incorrect;  try validating the code you posted.
Google found this explanation: http://lachy.id.au/log/2005/05/script-comments
Feeding even slightly invalid HTML to the standard library parser will often
choke it. If you can't guarantee clean sources, best use Tidy first or another
parser entirely.



-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to