I have a website at www.bdgregg.com.

The website was once hosted on a different server. I have moved the site to a new server. Everything remains the same as far as site content, images etc. However the images have stop loading for the different products. I have reloaded the database dump, re-uploaded images folder... but still the images will not load. It even appear as it the images are corrupt in some form. I am not sure why this would happen when the same files worked on another server without problems.


2 Answers 2


Visited the site and downloaded the broken image. 'file' identifies the file as a JPEG image, but on attempt to convert using image magick, the following error results:

convert: Corrupt JPEG data: 17 extraneous bytes before marker 0xc4 `120620vf4uozitjpeg' @ warning/jpeg.c/JPEGWarningHandler/348.
convert: Invalid JPEG file structure: SOS before SOF `120620vf4uozitjpeg' @ error/jpeg.c/JPEGErrorHandler/318.

Looks like the image files are corrupted in some fashion.

  • If you still have the original files, it might be worthwhile to test them to see if they load correctly, and if they do, perhaps re-copy them over to the new site to see if that doesn't fix it. Apr 24, 2013 at 18:09
  • Checking your "rims" selection, one image looks like it's corrupted in a different location, allowing partial image display: bdgregg.com/images/rim/Ultra%20Wheels/1008105i5ownszjpeg Apr 24, 2013 at 18:11

There's two problems that I can see, one that your response headers are reporting the images as plain/text.

Below is one of your images processing as text/plain:

Accept-Ranges   bytes
Connection  Keep-Alive
Content-Length  74107
Content-Type    text/plain
Date    Wed, 24 Apr 2013 20:11:35 GMT
Keep-Alive  timeout=5, max=75
Last-Modified   Sat, 20 Apr 2013 13:07:37 GMT

This is what the content type should be processing as:

Content-Type    image/jpeg

However this is likely because you are not using an extension on the image names, I recommend you use *.jpg or add the non-extension to caching.

Additionally as Wing Tang Wong as mentioned the images look damaged, I assume that you downloaded the files using FTP or SSH and then manually uploaded them using FTP or some other file manager. I strongly recommend that you zip the files on the original server then download the zip and upload the zip and then have the new server uncompress the files, this way if the zip is damaged it won't unzip (or least it shouldn't) and if it does then you know the images are intact.

  • Probably one of the tools in the chain applied line ending conversion onto the images, as it thougt they were text. You can also compare some md5 values of some images to see wether they came over helaltily. Apr 26, 2013 at 7:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.