le nom du fichier non predictible

This commit is contained in:
Christophe 2022-09-27 16:51:40 +02:00
parent 8df4aaf7cf
commit ce238e0fed

View file

@ -11,7 +11,7 @@ function action_pdf_gamutable_dist() {
}
$fichierpdf = _request('fichierpdf') ?? '';
$namepdf = _request('namepdf') ?? $fichierpdf;
// $namepdf = _request('namepdf') ?? $fichierpdf;
$header = _request('header') ?? [];
$Tdata = _request('data') ?? [];
$arg = _request('arg') ?? '';
@ -43,6 +43,7 @@ function action_pdf_gamutable_dist() {
include_spip('spipdf_options');
include_spip('inc/spipdf');
$namepdf = 'pdf_' . time();
$a = spipdf_html2pdf($fond);
$dir = sous_repertoire(_DIR_IMG . 'pdfgamutable');
$chemin = $dir . md5($namepdf) . '.pdf' ;