I am using the following code to open a pdf document. The pdf document is stored outside of the root directory:
$file = $_GET['file'];
$fileDir = '../../c_direc/';
if (file_exists($fileDir . $file))
{
$contents = file_get_contents($fileDir . $file);
header('Content-type: application/pdf');
echo $contents;
}
This code works (the pdf file opens) in firefox/Opera/Safari.. however in Internet Explorer, I am just getting a blank page.
Any suggestions are very much appreciated!