This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ezio.melotti
Recipients amaury.forgeotdarc, ezio.melotti, r.david.murray, serhiy.storchaka, vstinner, wrohdewald
Date 2014-10-31.17:49:33
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1414777773.22.0.236508564243.issue22746@psf.upfronthosting.co.za>
In-reply-to
Content
> In normal HTML utf-8 works fine, doesn't it?

It does, in fact as long as the encoding used by the browser matches the one used in the file, no charrefs needs to be used (except &gt; &lt; and &quot;).  Of course, if non-Unicode encodings are used, the range of available characters that can go directly in the HTML will be more limited, but this can be solved by using charrefs -- the browser will display the corresponding character no matter what is the encoding.  This also means that if charrefs are used for all non-ASCII characters, then the browser will be able to display the page no matter what encoding is being used (as long as it's ASCII-compatible, and most encoding are).  The downside is that it will make the source less readable and possible longer, especially if there are lot of non-ASCII characters, but if most of the characters are expected to be ASCII, using charrefs might be ok.
History
Date User Action Args
2014-10-31 17:49:33ezio.melottisetrecipients: + ezio.melotti, amaury.forgeotdarc, vstinner, r.david.murray, wrohdewald, serhiy.storchaka
2014-10-31 17:49:33ezio.melottisetmessageid: <1414777773.22.0.236508564243.issue22746@psf.upfronthosting.co.za>
2014-10-31 17:49:33ezio.melottilinkissue22746 messages
2014-10-31 17:49:33ezio.melotticreate