X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=lib%2FBackupPC%2FCGI%2FRestore.pm;h=494372b0f6172c82accaf2c4a60b0f0f54da2254;hp=e494ace3cf610b4c143206a149019d0039ae56fa;hb=b81d2da5e16975674f011e4833337ac0fa24e0ea;hpb=5b3e6091d542c2e7445d5dd511cdf6e20aec8b8d diff --git a/lib/BackupPC/CGI/Restore.pm b/lib/BackupPC/CGI/Restore.pm index e494ace..494372b 100644 --- a/lib/BackupPC/CGI/Restore.pm +++ b/lib/BackupPC/CGI/Restore.pm @@ -28,7 +28,7 @@ # #======================================================================== # -# Version 3.0.0alpha, released 23 Jan 2006. +# Version 3.0.0beta2, released 11 Nov 2006. # # See http://backuppc.sourceforge.net. # @@ -40,6 +40,7 @@ use strict; use BackupPC::CGI::Lib qw(:all); use Data::Dumper; use File::Path; +use Encode; sub action { @@ -73,6 +74,7 @@ sub action $hiddenStr .= < EOF + $name = decode_utf8($name); $fileListStr .= < ${EscHTML($name)} EOF @@ -110,6 +112,7 @@ EOF # # Tell the user what options they have # + $pathHdr = decode_utf8($pathHdr); $content .= eval("qq{$Lang->{Restore_Options_for__host2}}"); if ( @hosts == 1 ) { @@ -261,10 +264,16 @@ EOF (my $strippedShareDest = $In{shareDest}) =~ s/^\///; substr($targetFile, 0, length($pathHdr)) = "/$In{pathHdr}/"; $targetFile =~ s{//+}{/}g; + $strippedShareDest = decode_utf8($strippedShareDest); + $targetFile = decode_utf8($targetFile); + $strippedShare = decode_utf8($strippedShare); + $f = decode_utf8($f); $fileListStr .= <$host:/$strippedShare$f$In{hostDest}:/$strippedShareDest$targetFile EOF } + $In{shareDest} = decode_utf8($In{shareDest}); + $In{pathHdr} = decode_utf8($In{pathHdr}); my $content = eval("qq{$Lang->{Are_you_sure}}"); Header(eval("qq{$Lang->{Restore_Confirm_on__host}}"), $content); Trailer();