Andreas Jung wrote:
security.declareProtected(change_page_templates, 'PUT') def PUT(self, REQUEST, RESPONSE): """ Handle HTTP PUT requests """ self.dav__init(REQUEST, RESPONSE) self.dav__simpleifhandler(REQUEST, RESPONSE, refresh=1) ## XXX this should be unicode or we must pass an encoding self.pt_edit(REQUEST.get('BODY', '')) RESPONSE.setStatus(204) return RESPONSE
As you can see from the comment..there is some work to do.
Yay ;-)
AFAIK WevDAV the encoding is not available from a WebDAV request?!
Really? :-(
On the other hand there is code available that tries to obtain the encoding from the XML preamble (sniffEncoding)...
where?
and the very other hand there is still a problem with this method since the encoding can be determined by the BOM (if available)...this currently not handled through the code...I think I'll have a closer look at the code once again this week.
What's a BOM when it's at home? cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk