Greg Wilson <[EMAIL PROTECTED]> wrote:
> I realize I should include the Unicode characters directly in my files,
> but that's not possible in this case---I have to accommodate people who
> are using editors that only handle 7-bit ASCII.
Theoretically, .toxml('us-ascii') should generate usable out
Greg Wilson wrote at 2005-7-1 15:45 -0400:
>I realize I should include the Unicode characters directly in my files,
>but that's not possible in this case---I have to accommodate people who
>are using editors that only handle 7-bit ASCII.
Then, you need to implement an entity reference node (DOM ex
Greg Wilson wrote:
> Dieter Maurer wrote:
> > "Minidom"s support for entities is weak.
> >
> > Try to avoid them (beside the standard XML entities) by
> > using the corresponding Unicode characters instead.
>
> I realize I should include the Unicode characters directly in my files,
> but that's n
Dieter Maurer wrote:
> "Minidom"s support for entities is weak.
>
> Try to avoid them (beside the standard XML entities) by
> using the corresponding Unicode characters instead.
I realize I should include the Unicode characters directly in my files,
but that's not possible in this case---I have t
Greg Wilson wrote at 2005-6-30 12:19 -0400:
>This one must have come up several times before, but neither Google nor
>the Cookbook have given me an answer. I'm doing this:
>
>data = sys.stdin.read()
>doc = xml.dom.minidom.parseString(data)
>root = doc.documentElement
>...add and modify some nodes
This one must have come up several times before, but neither Google nor
the Cookbook have given me an answer. I'm doing this:
data = sys.stdin.read()
doc = xml.dom.minidom.parseString(data)
root = doc.documentElement
...add and modify some nodes...
sys.stdout.write(root.toxml('utf-8'))
A typica