From: Marcus Ramberg Date: Thu, 16 Sep 2004 19:40:05 +0000 (+0000) Subject: changed to set document encoding from config->{document_encoding} X-Git-Tag: 2.10~173 X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=9b27a09c3eefdad91ae3da125ea5dc71d08ed662;p=maypole.git changed to set document encoding from config->{document_encoding} defaults to utf-8 git-svn-id: http://svn.maypole.perl.org/Maypole/trunk@189 48953598-375a-da11-a14b-00016c27c3ee --- diff --git a/lib/Apache/MVC.pm b/lib/Apache/MVC.pm index f7eb317..3294df0 100644 --- a/lib/Apache/MVC.pm +++ b/lib/Apache/MVC.pm @@ -42,7 +42,7 @@ sub parse_args { sub send_output { my $r = shift; - $r->{ar}->content_type( $r->{content_type} ); + $r->{ar}->content_type( $r->{content_type}."; charset=".$r->{document_encoding} ); $r->{ar}->headers_out->set( "Content-Length" => length $r->{output} ); APACHE2 || $r->{ar}->send_http_header; $r->{ar}->print( $r->{output} ); diff --git a/lib/CGI/Maypole.pm b/lib/CGI/Maypole.pm index e112913..b937d82 100644 --- a/lib/CGI/Maypole.pm +++ b/lib/CGI/Maypole.pm @@ -40,6 +40,7 @@ sub send_output { my $r = shift; print $r->{cgi}->header( -type => $r->{content_type}, + -charset => $r->{document_encoding}, -content_length => length $r->{output}, ); print $r->{output};