I am using php to secure some images, and using readfile to send the image to the screen
only problem I have is, netscape picks up that the images are .jpg, but ie thinks they are .bmp (or rather nothing at all). How do I tell ie that the thumbnails are .jpg (other than sending "Content-type")
here are the headers I am sending.
header("Pragma: no-cache");
header("Content-type: image/jpeg");
header("Content-Length: ". filesize($path));
get info about this browser - IE 5.x is acting up
if(strstr($HTTP_USER_AGENT,"MSIE 5.")){
stupid IE hack:
header("Content-Disposition: filename=".$url_array[9]);
} else {
correct format:
header("Content-Disposition: attachment; filename=".$url_array[9]);
}
header("Content-Transfer-Encoding: binary");
readfile($path);