firefox .pdf file opening error
I have asp .net website where I open a .pdf file. It opens fine on IE but refuses to open on firef开发者_高级运维ox or other browsers. Why is that?
Error - There was an error processing a page. There was a problem reading this document (109)
A few things to check:
- Are you setting the content-type correctly?
- Are you url-encoding the PDF's file name?
- If you save the PDF to disk, does it open with a standard PDF reader?
It would also be good to know where the PDF is coming from. Is it just a static resource or are you generating it?
Verify whether your website is using any sort of compression for static files.
If it is, make sure that this is also being applied to the PDFs that are being served. I know it sounds odd, but this turned out to be my issue. Turning on compression for that particular file extension resolved it.
精彩评论