header if ($ftype=='gif') {
header('Content-type: image/gif');
header('Content-Disposition: inline; filename="' . $fname.".".$ftype . '"');
@readfile($downfile);
exit;
}elseif ($ftype=='jpg' or $ftype=='jpeg') {
header('Content-type: image/jpeg');
header('Content-Disposition: inline; filename="' . $fname.".".$ftype . '"');
@readfile($downfile);
exit;
}
$mime_type="application/octetstream";
header('Content-Type: ' . $mime_type);
header("Content-Length: ".$fcon[fsize]);
header('Content-Disposition: inline; filename="' . $fname.".".$ftype . '"');
header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
header('Pragma: public');
@readfile($downfile);