Skip to content

Commit

Permalink
fixed utf-8 issue
Browse files Browse the repository at this point in the history
  • Loading branch information
thawn committed Jan 23, 2017
1 parent 0efcb61 commit ecbb492
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions src/ttmp32gme.pl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ package main;
use PAR;

use Encode qw(decode_utf8 encode_utf8);
use utf8;

use Path::Class;

Expand Down Expand Up @@ -427,17 +428,15 @@ sub getNavigation {
my ( $httpd, $req ) = @_;
if ( $req->method() eq 'GET' ) {
$req->respond(
{
content => [
'text/html',
$templates{'pdf'}->fill_in(
HASH => {
'strippedTitle' => 'PDF',
'content' => $printContent
}
)
]
}
[
200, 'OK',{'Content-Type' => 'text/html'},
$templates{'pdf'}->fill_in(
HASH => {
'strippedTitle' => 'PDF',
'content' => encode_utf8( $printContent )
}
)
]
);
}
},
Expand Down

0 comments on commit ecbb492

Please sign in to comment.