Forum Moderators: not2easy

Message Too Old, No Replies

"Image cannot be displayed because it contains errors"

Does anyone know how to fix this?

         

mattypython

8:10 pm on Jan 9, 2006 (gmt 0)

10+ Year Member



I recently switched hosting providers and now some of my pngs aren't displaying in my site. When I access the image directly in the browser it says:

The image “http://www.example.com/button_bg.png” cannot be displayed, because it contains errors.

Has anyone run into this problem or know how to fix it? My old server was a Windows box and the new one is Apache if that helps.

<Sorry, no personal URLs.
See Terms of Service [webmasterworld.com]>

[edited by: tedster at 8:13 pm (utc) on Jan. 9, 2006]

john_k

8:32 pm on Jan 9, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



What happens if you ftp the file to your hard drive and then open the local version in your browser?

cws3di

8:35 pm on Jan 9, 2006 (gmt 0)

10+ Year Member




.png files should be served just fine on a unix/linux server.

The only thing I can think of that might be the problem is that possibly you uploaded them as ascii instead of binary.

Check through the menus on your FTP tool to make sure that you upload all image files as binary (i.e. don't use the Automatic button, or make sure the options are set up for .png as well as .jpg and .gif)
.

mattypython

8:55 pm on Jan 9, 2006 (gmt 0)

10+ Year Member



That was it! It went as ASCII. Thanks guys!