Question

I have a url similar to /abc/1.png i then rewrite it to /full/path/1.png. However it seems like the mime is being clobbered because when hitting view image with firefox i get a download instead of a page with the image. How do i solve this? I am using C# and ASP.NET you can view this post for more details Why are image acting as downloads?

Was it helpful?

Solution

I suspect that the MIME type of your friendly name is not correct? Can you show an example of the code you are using to render your friendly name version of the image?

Updated:

If your site is trying to serve images directly from asp.net code you need to set the response headers with the mime type of the image you're trying to return...

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top