1.1 --- a/MoinShare.py Fri Jun 14 01:19:43 2013 +0200
1.2 +++ b/MoinShare.py Fri Jun 14 15:59:21 2013 +0200
1.3 @@ -169,9 +169,9 @@
1.4 if format == "html":
1.5 update.content = body
1.6 elif hasattr(parser, "formatForOutputType"):
1.7 - s = StringIO()
1.8 + s = codecs.getwriter("utf-8")(StringIO())
1.9 parser.formatForOutputType("text/html", write=s.write)
1.10 - update.content = s.getvalue()
1.11 + update.content = unicode(s.getvalue(), "utf-8")
1.12 else:
1.13 fmt = request.html_formatter
1.14 fmt.setPage(page)
2.1 --- a/macros/SharedContent.py Fri Jun 14 01:19:43 2013 +0200
2.2 +++ b/macros/SharedContent.py Fri Jun 14 15:59:21 2013 +0200
2.3 @@ -332,6 +332,8 @@
2.4 append(fmt.div(on=1, css_class="moinshare-update"))
2.5 append(fmt.div(on=1, css_class="moinshare-content"))
2.6
2.7 + # NOTE: Handle multipart/alternative.
2.8 +
2.9 if update.content:
2.10 if update.content_type == "text/html" and update.message_number is not None:
2.11 parsers = [get_make_parser(update.page, update.message_number)]