通过url路径下载服务器文件
html
<iframe width=0 height=0 frameborder=0 name=hrong style="display: none"></iframe>
js
window.frames["hrong"].location.href = "文件地址";
sa();
function sa()
{
if(window.frames["hrong"].document.readyState!="complete")
setTimeout("sa()", 100);
else
window.frames["hrong"].document.execCommand('SaveAs');
}