Tornadoでattachment
Tornadoでヘッダーを弄ってattachmentでダウンロードさせる
self.set_header("Content-Type", "application/octet-stream") self.set_header("Content-Disposition", "attachment; filename=file.jpg")
ヘッダをセットしたのでファイルをwrite
self.write(downloadFile)
Tornadoでヘッダーを弄ってattachmentでダウンロードさせる
self.set_header("Content-Type", "application/octet-stream") self.set_header("Content-Disposition", "attachment; filename=file.jpg")
ヘッダをセットしたのでファイルをwrite
self.write(downloadFile)