Thanks, Duncan. That did the trick.
If you're EuroPythoning, I'll buy you a drink.
Cheers.
Duncan Booth wrote:
> First up, when I repeat what you did I don't get the same output. toxml()
> without an encoding argument produces a unicode string, and no encoding
> attribute in the
>
> toxml()
Dale Strickland-Clark wrote:
> from xml.dom.minidom import parseString
> output = parseString(strHTML).toxml()
>
> The output is:
>
>
>
>
>
>http-equiv="Content-Type"/>
>
> â¬
>
>
>
> So it encodes the entity reference to ⬠(Euro sign).  I need it to
> remain as € so that the resulting HTM
Dale Strickland-Clark enlightened us with:
> So it encodes the entity reference to ⬠(Euro sign).  I need it to
> remain as € so that the resulting HTML can render properly in
> a browser.
If you want proper display, why not use UTF-8?
Sybren
--
The problem with the world is stupidity. Not sa