index eb36008b1029891a6aa1093a21f6c9a06ceeb336..58bab226ba7b70656e4075a2cfe669b5eb7e9733 100644 (file)
--- a/html/get_attachment.php
+++ b/html/get_attachment.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
gosa_log ("Error: get_attachment.php called without session");
- header ("Location: ../index.php");
+ header ("Location: index.php");
exit;
}
$ui= $_SESSION["ui"];
return;
}
-if(!is_readable("/etc/gosa/glpi/".$att['filename'])){
- print sprintf(_("Can't open file '%s'."),"/etc/gosa/glpi/".$att['filename']);
+if(!is_readable(CONFIG_DIR."/glpi/".$att['filename'])){
+ print sprintf(_("Can't open file '%s'."),CONFIG_DIR."/glpi/".$att['filename']);
}
-$data = file_get_contents("/etc/gosa/glpi/".$att['filename']);
+$data = file_get_contents(CONFIG_DIR."/glpi/".$att['filename']);
/* force download dialog */
header("Content-type: ".$att['mime']."\n");