Opening files in browser instead of downloading

后端 未结 4 1035
执念已碎
执念已碎 2020-12-16 14:37

I have a href link to a pdf file that when clicked on it downloads. I want this to just open in a new page instead of downloading.



        
4条回答
  •  一生所求
    2020-12-16 15:02

    The server tells the browser whether the content you are getting is "inline" or not. If you are controlling the server, you will want to change the server's settings for whether to serve the problematic file as an attachment. Otherwise, there are browser plug-ins which allow you to override this. For Firefox, there is Open in Browser; http://spasche.net/openinbrowser/

提交回复
热议问题