mò &á¸Ec@s‰dZdkZeideiƒZeideieiBeiBƒZeideieiBeiBƒZd„Z d„Z d„Z dS(sY Some helper methods $Id: ZopePageTemplate.py 71579 2006-12-17 20:26:10Z andreasjung $ Ns ^<\?xml.*?encoding="(.*?)".*?\?>s(()s"charset.*?=.*?(?P[\w\-]*)cCs5ti|ƒ}|pdSn|idƒiƒSdS(sW Extract the encoding from a xml preamble. Return 'utf-8' if not available sutf-8iN(txml_preamble_regtmatchtxmltmotgrouptlower(RR((t;/data/zmath/zope/lib/python/Products/PageTemplates/utils.pytencodingFromXMLPreambles cCsZti|ƒ}|o@|idƒ}ti|ƒ}|o|idƒiƒSqVndS(sº Return the value of the 'charset' from a html document containing