How to set response filename without forcing “save as” dialog

元气小坏坏 提交于 2019-11-27 17:21:56
Patonza

The correct way could be:

Content-Disposition: inline; filename="myfile.txt"

Rubens Farias

I'm not sure if that's possible by default. Due to security concerns, browsers don't send all content-types they can handle, but just a few Accept-Encoding, which doesn't help a lot in your scenario.

Maybe you can ask your user what they prefer and store that information in their profile.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!