Utilisation de la fonction tempnam pour les noms de fichier de l'action
image2svg
This commit is contained in:
parent
a7076e962a
commit
57b8d8d973
4
app.php
4
app.php
|
@ -85,9 +85,9 @@ $f3->route('POST /image2svg',
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}, true, function($fileBaseName, $formFieldName) {
|
}, true, function($fileBaseName, $formFieldName) use ($f3) {
|
||||||
|
|
||||||
return substr(hash('sha256', $fileBaseName.uniqid().mt_rand()), 0, 24).strrchr($fileBaseName, '.');
|
return basename(tempnam($f3->get('UPLOADS'), 'pdfsignature_image2svg'));
|
||||||
});
|
});
|
||||||
|
|
||||||
$imageFile = null;
|
$imageFile = null;
|
||||||
|
|
Loading…
Reference in New Issue