在通过response导出文件数据的时候,不论是txt 还是Excel ,如果想让其文件名称为中文,解决方案:
response.setCharacterEncoding("UTF-8");
response.setContentType("application/txt");//“application/vnd.ms-excel”
response.setHeader("Content-disposition","p_w_upload; filename="+new String(filename.getBytes("UTF-8"),"iso8859-1"));