ie通过window.open下载excel,结果是直接打开excel乱码
在应用中通过window.open(filename,'_self')下载excel时,变成直接在浏览器打开excel,而且还是乱码,在网上找了很多办法,如设置web.xml,在web.xml增加
var w = window.open("","_self"); w.location.href=fileUrl;
通过以上代码,在ie中会弹出对话框,提示保存。
作者:阿里巴巴taba 1 楼 JeffreyHsu 2011-08-31 有用!!!