I am trying to publish a link from an image to a pdf I uploaded into assets. The type is “file”. The asset status is “live”. When I preview the asset from the UI, it displays as it should. However, the link on my published site returns a long page of weird letters and numbers.
To clarify, are you linking to the PDF through an image in a Rich Text editor? When you preview the page which contains this link, can you successfully follow the link to the asset that way (in other words, the problem is totally isolated to your published site)?
Thanks so much for your reply. I believe the issue was that I had a space in the name of the file.
To fix this issue you would need to add a Multipurpose Internet Mail Extensions or MIME type for pdf files. Since we had created a MIME type with a wildcard (*). This tells IIS that anything it does not have a MIME type for it should display as text/html.
This includes PDFs since there is no MIME type for this by default in IIS6.
To fix this issue I did the following:
I went into the ISS manager right-clicked and selected the site to view the properties of the site
I then clicked on the HTTP Header tab and on the MIME Types… button at the bottom.
- Added in a extentison type of .pdf and a MIME type of application/pdf. I also added one for PNG
You will may need to add additional MIME types depending on your configuration. Here is a listing of some from an aritcle on Microsoft’s TechNet