This happens in Firefox, but not in Google Chrome.
I create an SVG 'Image' tag in an svg-web canvas like this:
im = document.createElementNS(svgns, 'image');
im.setAttributeNS(xlinkns, 'href', g.href);
canvas.appendChild(im);
And if I look in firebug or chrome's debugger, the svg shows up self-closed like this:
<image xlink:href="..." />
But if I then print the parent of the svg element's innerHTML
, it returns this:
<svg><image xlink:href="..."></svg>
Note that the image tag is now unclosed, which causes errors down the line. Have I discovered a bug, or am I doing something wrong? And, probably much harder, is there a way in JavaScript to check and fix the tag?