[thelist] PHP, PDF and IE7

Hershel Robinson hershel at galleryrobinson.com
Mon Mar 12 09:41:10 CDT 2007


This PHP code:

if ($fp = fopen($filename, 'rb')) {
$len = filesize($filename);
header('Content-Title: Mishpacha PDF Article');
header('Content-Type: Mishpacha PDF Article application/pdf');
header("Content-Length: $len");
fpassthru($fp);
fclose($fp);
} else {
echo 'Invalid File?<br>';
echo $file[filename];
}

works to deliver a PDF in FF2 and IE6. In IE7, however, Windows XP 
doesn't seem to realize that it's a PDF file.

The code is online here:

http://mishpacha.com/pdfrequest/1/149/40/

You need only to enter an email and then submit.

Any ideas?

Thanks,
Hershel

-- 
Web Site Construction by Gallery Robinson
http://galleryrobinson.com/



More information about the thelist mailing list