jlh3302
jlh3302

Reputation: 123

500 Internal Server Error accessing Image in IIS7

I have created an ASP.Net MVC4 site and deployed it to IIS7.

We noticed that the images in the css were not showing.

Trying to directly access the image file like this http://.com/CircuitSearch/Images/CircuitSearchBackgroundTrans.png returns the 500 error. Yes the filepath is correct.

Odd part if another site hosted on the same IIS works fine and can display images.

Upvotes: 4

Views: 8167

Answers (2)

AdamantineWolverine
AdamantineWolverine

Reputation: 2181

I went into the IIS Log (usually under c:\inetpub\Logs) and discovered that I was getting error 500 with sub status of 19.

I looked up the causes for 500.19 via google and found the below link: https://support.microsoft.com/en-us/help/942055/http-error-500-19-error-when-you-open-an-iis-7-0-webpage

Based off a clue that there could be a duplicate entry for some of the modules, handlers, or mime types causing an error, I commented out my system.webServer and noticed the images worked. I then commented out only portions of my web config and narrowed it down to a duplicate staticContent entry in my web.config.

Upvotes: 4

helpME1986
helpME1986

Reputation: 1013

Change authentication for the site to Anonymous authentication/ application pool identity

enter image description here

Upvotes: 6

Related Questions