liferay plugin 开发导出excel怎么设置head信息? liferay plugin 开发导出excel怎么设置head信息? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 /*设置文件下载的头信息*/LiferayRenderResponse liferayRes = (LiferayRenderResponse)res;liferayRes.setContentType("application/x-download");liferayRes.addProperty(HttpHeaders.CACHE_CONTROL, "max-age=3600, must-revalidate");liferayRes.addProperty("Content-disposition", "attachment; filename=students.xls");// 设定输出文件头OutputStream out = liferayRes.getPortletOutputStream();exportStudents(out, req, signers); 发个面试时的经典题目 新手请教package等问题 用SimpleDateFormat把时间格式化问题 一个有意思的Java问题.谁知道? 关于Applet的问题(内网可以启动Applet,但外网不能) 求一个正则表达式,简单。 类型判断的问题 关于null和垃圾回收的问题 关于JB8的错误 北京现在还买不到程序员JAVA刊!不是说已经上市了么?骗子!骗子!!!! 关于GUI sql里 max(id)的问题
LiferayRenderResponse liferayRes = (LiferayRenderResponse)res;liferayRes.setContentType("application/x-download");
liferayRes.addProperty(HttpHeaders.CACHE_CONTROL, "max-age=3600, must-revalidate");
liferayRes.addProperty("Content-disposition", "attachment; filename=students.xls");// 设定输出文件头
OutputStream out = liferayRes.getPortletOutputStream();
exportStudents(out, req, signers);