My 404.html contains:
<img class="img-responsive center-block" src="Images/error404.png"/>
My Web.config in the project folder contains:
<httpErrors errorMode="Custom" existingResponse="Replace">
<remove statusCode="404"/>
<error statusCode="404" path="404.html" responseMode="File"/>
</httpErrors>
I can access image through http://localhost:53870/Images/error404.png
in browser.
Image in 404.html is loading when i call it directly
localhost:53870/404.html
Or when i call
http://localhost:53870/NonexistentController
Image in 404.html ISN'T loading when i call something like this
http://localhost:53870/Home/NonexistentAction