SVG parser doesn’t recognize XML namespace |
||||||
Issue description
Chrome Version : 53.0.2785.116
OS Version: OS X 10.11.6
URLs (if applicable) :
Other browsers tested:
Add OK or FAIL after other browsers where you have tested this issue:
Safari 5: FAIL
Firefox 4.x: FAIL
IE 7/8/9: not tested
What steps will reproduce the problem?
1. Open the attached “a.html” and “b.html”.
What is the expected result?
You should see a black ellipse in both documents. In terms of XML syntax, the two files are structurally equivalent, so (as far as I can tell) they should get rendered in the same way.
What happens instead of that?
The SVG image in document “b.html” is not rendered. Apparently, the HTML browser fails to properly handle the XML namespace.
Please provide any additional information below. Attach a screenshot if
possible.
The document “b.html” was generated from “a.html” with the following script:
#!/usr/bin/python2.7
import xml.etree.ElementTree as etree
print etree.tostring(etree.parse('a.html').getroot())
UserAgentString: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.116 Safari/537.36
,
Sep 21 2016
,
Sep 21 2016
,
Sep 21 2016
fs@, do you know if this is supposed to work? The other browsers fail, which makes me wonder. And, from memory, I thought the SVG 2.0 spec removes all the xml ns handling requirements.
,
Sep 21 2016
This is more a question of HTML vs. XHTML. The HTML will not recognize this as SVG, but if you turned into XHTML (by opening the http://www.w3.org/1999/xhtml namespace) it would. The HTML parser does not recognize NS declarations in general.
,
Sep 22 2016
Setting as WontFix, since I don't see any bugs here (although ElementTree could do with better serialization code ;-))
,
Sep 29 2016
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by sascha@google.com
, Sep 21 2016