Visual Studio 2008 Web Project problem with PNG files
- by NoCarrier
I've added a PNG file to a directory in my VS2k8 webforms project, and when I run the app, it refuses to render my image - it even knows the dimensions but renders a box with a red X.
Oddly enough, if I double click the PNG file within VS2k8, it opens up in the IDE and displays fine (but only within the IDE).
Does anyone have any clues?
The path is correct.. I just have a basic default.aspx page with this in the body
<img src="img/logo.png" />
if i navigate to img/logo.png in the browser, it shows a box with the same dimensions as my image, but a red x. Its finding the image, just not rendering it. It's showing up in IE running under the vs2k8 web server (localhost:5512/default.aspx)
I've dropped a JPG in the same directory, and it shows up just fine.
I'm not sure what type of PNG it is, but here is the kicker.... If i make an HTML file that references that image, copy both this HTML file and PNG file to my webserver (or just double click on the HTML page), it comes up JUST FINE.
Its leading me to believe that the Visual Studio web server may not recognize PNG files (at least this one) properly?