打开:xenforo\library\XenForo\ViewPublic\Attachment\view.php
更改如下:
if (in_array($extension, array_keys($imageTypes)))
{
$this->_response->setHeader('Content-type', $imageTypes[$extension], true);
//chinese file name encoder
//$this->setDownloadFileName($attachment['filename'], true);
$this->setDownloadFileName( (@iconv("UTF-8", $charsett, $attachment['filename'])), true);
//chinese file name encoder end
}
else
{
$this->_response->setHeader('Content-type', 'unknown/unknown', true);
//chinese file name encoder
//$this->setDownloadFileName($attachment['filename']);
$this->setDownloadFileName(@iconv("UTF-8", $charsett, $attachment['filename']));
//chinese file name encoder end
}

1 对 “xenforo的中文附件名在IE环境中下载乱码的解决办法”的想法;

发表评论

电子邮件地址不会被公开。 必填项已用*标注