mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 18:03:17 +00:00
filter special characterin filename when created lazaretfile
This commit is contained in:
@@ -54,6 +54,9 @@ class LazaretPathBooker
|
|||||||
*/
|
*/
|
||||||
public function bookFile($filename, $suffix = '')
|
public function bookFile($filename, $suffix = '')
|
||||||
{
|
{
|
||||||
|
// stripped all non-alpha-numeric in filename
|
||||||
|
$filename = preg_replace("/[^a-zA-Z0-9-_.]/", '', $filename);
|
||||||
|
|
||||||
$output = $this->tmpPath .'/lzrt_' . substr($filename, 0, 3) . '_' . $suffix . '.' . pathinfo($filename, PATHINFO_EXTENSION);
|
$output = $this->tmpPath .'/lzrt_' . substr($filename, 0, 3) . '_' . $suffix . '.' . pathinfo($filename, PATHINFO_EXTENSION);
|
||||||
$infos = pathinfo($output);
|
$infos = pathinfo($output);
|
||||||
$n = 0;
|
$n = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user