简体   繁体   English

Internet Explorer的内容处置内联文件名问题

[英]Content-Disposition inline filename issue with internet explorer

HTTPResponse object: HTTPResponse对象:

final httpResponse 最终的httpResponse

HTTP/1.1 200 
Vary: Accept-Encoding
Content-Type: application/pdf
Content-Dis;filename*=utf-8''aproved.pdf
Expires: 0
Cache-Control: must-revalidate, post-check=0, pre-check=0
Pragma: public
Content-Encoding: gzip

where the content-disposition is taking the filename as we are passing (approved.pdf) 内容处置在我们通过时采用文件名的地方(approved.pdf)

But when we save the the pdf from the viewer in IE ,it saves as Downlaod.pdf(where Download is the servlet name) 但是,当我们从IE中的查看器中保存pdf时,它另存为Downlaod.pdf(其中Download是servlet名称)

The same usecase works fine in other browsers(chrome) by saving with the actual filename.pdf using the Content-Dispostion 通过使用Content-Dispostion使用实际的filename.pdf保存,该用例在其他浏览器(chrome)中也可以正常工作

Need help on this for IE browser. 在IE浏览器上需要帮助。

Shouldn't it be: 不应该是:

Content-Type: application/pdf
Content-Disposition: inline; filename="aproved.pdf"

?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM