Image Header Issues - solved
| From: | Bob Eldred | Date: | Thu, 22 Jan 2004 02:46:15 +0000 |
| Subject: | Image Header Issues - solved | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-175386@lists.php.net to get a copy of this message | ||
For the archives, for when someone else runs into this. The following
headers solved the issue where IE would only save an image as a BMP,
when the image was, in fact, a JPG:
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-Type: image/jpeg");
header("Content-length: ".(string)filesize($fullpicturename));
header("Content-Disposition: inline;
filename=\"".$row["name"]."\"");
header("Content-Transfer-Encoding: binary");
My thanks to Larry Brown for his assistance. It seems that Justin
French isn't the only freaking genius on this list!
Bob