gestione gare pubbliche
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 
 
 

33 righe
1.1 KiB

<?
$configPath = substr(__DIR__,0,strpos(__DIR__,"/public_html"))."/config.php";
include_once($configPath);
$content = false;
if (empty($_POST["codice_elenco"]) && !empty($_GET["codice_elenco"])) {
$_POST = $_GET;
}
if (!empty($_SESSION["utente"]) && !empty($_POST["codice_richiesta"]) && tokenVerify($_POST["token"])) {
$elenco = publicAlboFornitori::init($_POST["codice_elenco"]);
if (!empty($elenco)) {
$partecipante = $elenco->miaPartecipazione();
if (!empty($partecipante)) {
$busta = $elenco->getBusta($partecipante["codice"],$_POST["codice_richiesta"],true);
if (!empty($busta)) {
$content = $busta["content"];
}
}
}
if ($content !== false) {
header('Content-Type: ' . $busta["mime"]);
header('Content-Disposition: attachment; filename='.str_replace("-",".",$busta["nomeFile"]));
header('Content-Transfer-Encoding: binary');
header('Expires: 0');
header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
header('Pragma: public');
echo $content;
} else {
header('HTTP/1.0 403 Forbidden');
echo __("Errore nella richiesta");
die();
}
}
?>