• R/O
  • SSH
  • HTTPS

fswiki: Commit


Commit MetaInfo

Revision202 (tree)
Time2018-04-17 18:55:33
Authorkgsoft

Log Message

BugTrack-wiki/351 : Edgeブラウザーにおけるダウンロードファイル名の文字化け対応

Change Summary

Incremental Difference

--- fswiki/trunk/fswiki/lib/Util.pm (revision 201)
+++ fswiki/trunk/fswiki/lib/Util.pm (revision 202)
@@ -723,7 +723,7 @@
723723 my ($filename, $disposition) = @_;
724724 my $ua = $ENV{"HTTP_USER_AGENT"};
725725 eval("use MIME::Base64;");
726- my $encoded = ( $ua =~ /MSIE|Trident/i ? Jcode->new($filename)->sjis
726+ my $encoded = ( $ua =~ /MSIE|Trident|Edge/i ? Jcode->new($filename)->sjis
727727 : $ua =~ /Chrome|Firefox/i ? "=?utf-8?B?".MIME::Base64::encode_base64(Jcode->new($filename)->utf8,'')."?="
728728 : Jcode->new($filename)->utf8 );
729729 return "Content-Disposition: $disposition;filename=\"".$encoded."\"\n\n";
Show on old repository browser