On Mon, Jan 23, 2006 at 10:15:43AM +0100, Thomas Guettler wrote:
-> Am Freitag, 20. Januar 2006 14:54 schrieb Graham Fawcett:
-> > Titus Brown wrote:
-> > "By default, SGML requires that all attribute values be delimited
-> > using either double quotation marks (ASCII decimal 34) or single
-> > quotation marks (ASCII decimal 39).
-> [cut]
-> > Don't have a ref at hand, but I am certain it's valid in XML as well.
->
-> Yes, XML allows single and double quotation marks:
->
-> AttValue ::= '"' ([^<&"] | Reference)* '"'
-> | "'" ([^<&'] | Reference)* "'"
->
-> https://www.w3.org/TR/2004/REC-xml-20040204/#NT-AttValue
(I didn't actually write that, but ok ;)
So, should htmlescape deal with this differently?
right now it does this:
>>> print str(htmlescape("'"))
'
>>> print str(htmlescape('"'))
"
--titus