summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-06-15 03:44:27 +0000
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-06-15 03:44:27 +0000
commit070f255d6cc16dd2eb6c53b40790a5fb905300af (patch)
tree828b81f7b851c4570dffc8e7d0f53db3872641e4
parent3405864bc4e4cf5efd7679dd81ec9ba054cb968b (diff)
* YA utf-8 patch from Recai, this time to fix previewing a page so that
the text in the input box is re-encoded back to utf-8.
-rw-r--r--IkiWiki/CGI.pm7
-rw-r--r--debian/changelog7
2 files changed, 12 insertions, 2 deletions
diff --git a/IkiWiki/CGI.pm b/IkiWiki/CGI.pm
index 986a8ee1d..4f4c48876 100644
--- a/IkiWiki/CGI.pm
+++ b/IkiWiki/CGI.pm
@@ -353,9 +353,12 @@ sub cgi_editpage ($$) { #{{{
}
elsif ($form->submitted eq "Preview") {
require IkiWiki::Render;
+ require Encode;
+ my $content = Encode::decode_utf8($form->field('editcontent'));
+ $form->field(name => "editcontent", value => $content, force => 1);
$form->tmpl_param("page_preview",
- htmlize($config{default_pageext},
- linkify($page, $page, $form->field('editcontent'))));
+ Encode::decode_utf8(htmlize($config{default_pageext},
+ linkify($page, $page, $content))));
}
else {
$form->tmpl_param("page_preview", "");
diff --git a/debian/changelog b/debian/changelog
index 99a729084..28d423ba6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ikiwiki (1.6) UNRELEASED; urgency=low
+
+ * YA utf-8 patch from Recai, this time to fix previewing a page so that
+ the text in the input box is re-encoded back to utf-8.
+
+ -- Joey Hess <joeyh@debian.org> Wed, 14 Jun 2006 23:38:40 -0400
+
ikiwiki (1.5) unstable; urgency=low
* Add --timeformat config option to allow changing how dates are displayed.