From 5604b352ec2b50f366bf1e649b63f41c9ed4a7a8 Mon Sep 17 00:00:00 2001 From: e Date: Fri, 19 Oct 2018 23:26:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8B=E8=BD=BD=E8=B7=AF=E5=BE=84=E5=8C=85?= =?UTF-8?q?=E5=90=AB=E4=B8=AD=E6=96=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../web/system/controller/core/SystemController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/jeecgframework/web/system/controller/core/SystemController.java b/src/main/java/org/jeecgframework/web/system/controller/core/SystemController.java index 2fab1fe3..3a332c9f 100644 --- a/src/main/java/org/jeecgframework/web/system/controller/core/SystemController.java +++ b/src/main/java/org/jeecgframework/web/system/controller/core/SystemController.java @@ -1307,7 +1307,7 @@ public class SystemController extends BaseController { if("1".equals(flag)){ response.setContentType("application/x-msdownload;charset=utf-8"); String fileName=dbpath.substring(dbpath.lastIndexOf(File.separator)+1); - response.setHeader("Content-disposition", "attachment; filename="+ new String(fileName.getBytes("utf-8"), "ISO8859-1")); + response.setHeader("Content-disposition", "attachment; filename="+ java.net.URLEncoder.encode(fileName, "UTF-8")); }else{ response.setContentType("image/jpeg;charset=utf-8"); }