惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Microsoft Azure Blog
Microsoft Azure Blog
aimingoo的专栏
aimingoo的专栏
F
Fortinet All Blogs
Blog — PlanetScale
Blog — PlanetScale
GbyAI
GbyAI
MongoDB | Blog
MongoDB | Blog
月光博客
月光博客
The Cloudflare Blog
量子位
T
Tailwind CSS Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
B
Blog
MyScale Blog
MyScale Blog
T
The Blog of Author Tim Ferriss
The GitHub Blog
The GitHub Blog
G
Google Developers Blog
D
DataBreaches.Net
V
Visual Studio Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Last Week in AI
Last Week in AI
U
Unit 42
博客园 - 聂微东
有赞技术团队
有赞技术团队
A
About on SuperTechFans

博客园 - 重粒子

文件在线预览doc,docx转换pdf(一) vue中集成pdfjs自定义分页 使用 vs code 搭建vue项目(一) css 文本超出2行就隐藏并且显示省略号 js监听全屏下的esc事件 js实现全屏和缩放 ionic 侧栏菜单用法 weblogic获取应用目录路径(war包) 使用pdf.js预览实现读取服务器外部文件 js禁用浏览器后退 java批量将多文件打包成zip格式 Angularjs自定义指令计算浏览器高度 AngularJS封装webupload实现文件夹上传 jquery监听滚动条 pdf预览(pdf.js) (钉钉)第三方WEB网站扫码登录 $q的基本用法 Jersey RESTful WebService框架学习(八)文件下载防乱码 巧用 Jersey RESTful WebService框架解决文件上传乱码
post文件下载
重粒子 · 2018-08-16 · via 博客园 - 重粒子
 this.$http({
          method: 'post',
          url: '/file/download',
          responseType: 'blob',
          data: JSON.stringify(this.theDocument)
        }).then(response => {
          let headers = response.headers
          let _blob = new Blob([response.data], {
            type: headers['Content-Type']
          })
          let _link = document.createElement('a')
          _link.href = window.URL.createObjectURL(_blob)
          _link.download = this.theDocument.thename
          _link.click()
        })