[XML-SIG] Sax2.FromXml 'feature'
Alexandre Fayolle
alf@logilab.com
Mon, 11 Sep 2000 09:56:35 +0200 (CEST)
Hi there,
I'm experiencing what I think is a weird behaviour of Sax2.FromXml(). If
you consider the following :
from xml.dom.ext.reader import Sax2
document = Sax2.FromXml('<doc/>')
fragment = Sax2.FromXml('<frag/>',document)
In the previous example, fragment is a document fragment that has document
as ownerDocument.
Now if I change the last line of the previous example to:
fragment = Sax2.FromXml('<frag/><frag/>',document)
I get an SAXParseException: Elements not allowed outside root element at
Unknown:1:12
Am I missing something ? How can I get a document fragment from some xml
text ?
--
Alexandre Fayolle
Logilab