per la cronaca, credo di aver risolto in questo modo
codice:
<?php
function download ($nome, $path) {
$size = filesize ($path);
$fp = fopen ($path, "rb");
$binary = fread ($fp, $size);
fclose ($fp);
$nome = stripslashes ($nome);
if (strpos($_SERVER['HTTP_USER_AGENT'],"Gecko")) {
$nome = strtolower ($nome);
$nome = str_replace("ä","a",$nome);
$nome = str_replace("ö","o",$nome);
}
header("Pragma: public");
header("Cache-control: private");
header("Expires: 0");
header("Content-type: application/RFC822");
header("Content-type: octet/stream\n");
header("Content-transfer-encoding: binary\n");
header("Content-Disposition: attachment; filename=".$nome."\n");
header("Content-Length:".$size);
echo $binary;
exit();
}
download ($_REQUEST['myFile'], $_REQUEST['path']);
?>
adesso faccio dei test