30 private const ZERO_JOINER =
'/\\x{00ad}|\\x{0083}|\\x{200c}|\\x{200d}|\\x{2062}|\\x{2063}/iu';
37 $filename = preg_replace(
'/[\x00-\x1F\x7F]/u',
'', $filename);
38 $filename = preg_replace(self::CONTROL_CHARACTER,
'', $filename);
41 $filename = preg_replace(self::FUNKY_WHITESPACES,
'', $filename);
42 $filename = preg_replace(self::SOFT_HYPHEN,
' ', $filename);
43 $filename = preg_replace(self::ZERO_JOINER,
'', $filename);
46 return \UtfNormal::NFC($filename);
static sanitizeFileName(string $filename)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This Util class is a collection of static helper methods to provide file system related functionality...