I'm using the basic script that everyone else seems to agree works best for forcing IE to "Save File As".
Something of this nature:
header("Content-Type: application/octet-stream");
header("Content-Disposition: attachment; filename=$name");
header("Content-Transfer-Encoding: binary");
$fh = fopen("/www/docs/$name", "r");
fpassthru($fh);
exit;
Unfortunately if the user chooses to "Open File From This Location" instead of "Save File As" and the file is HTML IE will still display the file in the browser. If the file contains any javascript that javascript will run (bad).
Does anyone know how to get around this vexing problem?
Thanks in advance
frodo