mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-11 17:44:56 +00:00
check if includecontent is set
if not set only the excel file is delivered
This commit is contained in:
parent
5d5d954077
commit
1a179c7dca
|
@ -423,12 +423,21 @@ if(isset($_GET["fullsearch"]) && $_GET["fullsearch"]) {
|
|||
}
|
||||
}
|
||||
$filename = tempnam('/tmp', '');
|
||||
if(isset($_GET['includecontent']) && $_GET['includecontent']) {
|
||||
$downmgr->createArchive($filename);
|
||||
header("Content-Transfer-Encoding: binary");
|
||||
header("Content-Length: " . filesize($filename));
|
||||
header("Content-Disposition: attachment; filename=\"export-" .date('Y-m-d') . ".zip\"");
|
||||
header("Content-Type: application/zip");
|
||||
header("Cache-Control: must-revalidate");
|
||||
} else {
|
||||
$downmgr->createToc($filename);
|
||||
header("Content-Transfer-Encoding: binary");
|
||||
header("Content-Length: " . filesize($filename));
|
||||
header("Content-Disposition: attachment; filename=\"export-" .date('Y-m-d') . ".xls\"");
|
||||
header("Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml. sheet");
|
||||
header("Cache-Control: must-revalidate");
|
||||
}
|
||||
|
||||
readfile($filename);
|
||||
unlink($filename);
|
||||
|
|
Loading…
Reference in New Issue
Block a user