halfjuice halfju...@gmail.com added the comment:
well, !-- ... - is ok since it's comment. !- ... - is probably a IE hack.
see http://www.google.com/dictionary?langpair=en|zh-CNq=vaguehl=enaq=f
--
status: pending - open
___
Python tracker
Georg Brandl ge...@python.org added the comment:
Is that URL really what you wanted to show me?
Also, I'm not intimate with all of SGML's syntax, but ISTM that what you show
here is invalid SGML, and as such SGMLParser is not required to parse it.
--
halfjuice halfju...@gmail.com added the comment:
Sorry, the URL on the page is sort of broken. The URL contains the !- ... -
stuff.
I think you're right, the !- is probably just a mistake which is not in the
SGML standard. But I'm wondering if the SGMLParser can SKIP such an invalid
Georg Brandl ge...@python.org added the comment:
The browser needs to be very liberal in what it accepts, since nobody wants
their page view to break because of such a technicality. This is different for
a tool like SGMLParser.
In light of this, and because sgmllib is removed anyway in Python
New submission from halfjuice halfju...@gmail.com:
When parsing html containing the following tag:
... !- ie6 doesn't allow empty div. - ...
SGMLParser will stop parse following content without any warning. When such tag
is removed everything works fine.
When looking into sgmllib.py, statement
Georg Brandl ge...@python.org added the comment:
Are you sure you got the comment syntax right? e.g.
!-- ie6 doesn't allow empty div. --
SGMLParser should handle that.
--
nosy: +georg.brandl
resolution: - works for me
status: open - pending
___