if(request.getHeader("User-Agent").toUpperCase().indexOf("MSIE") > 0){ response.setHeader("Content-disposition", "attachment; filename=" + URLEncoder.encode(product.getRealName1(), "UTF-8")); }else{ response.setHeader("Content-disposition", "attachment; filename=" + new String(product.getRealName1().getBytes("utf-8"), "ISO8859-1")); }
文件下载文件名乱码解决
时间: 2024-10-29 07:54:53