window.open()下载文件: 在当前页面打开方法 function downloadDocument () { var href="/xxxxxxxx/xxxxxxxx" window.open(href,'_self'); //在当前页面打开 }