Fix rename files with accents
This commit is contained in:
parent
4cff4c6935
commit
b8251bac97
@ -179,8 +179,8 @@ elseif ($action == 'renamefile' && GETPOST('renamefilesave','alpha'))
|
|||||||
// For documents pages, upload_dir contains already path to file from module dir, so we clean path into urlfile.
|
// For documents pages, upload_dir contains already path to file from module dir, so we clean path into urlfile.
|
||||||
if (! empty($upload_dir))
|
if (! empty($upload_dir))
|
||||||
{
|
{
|
||||||
$filenamefrom=dol_sanitizeFileName(GETPOST('renamefilefrom','alpha'));
|
$filenamefrom=dol_sanitizeFileName(GETPOST('renamefilefrom','alpha'), '_', 0); // Do not remove accents
|
||||||
$filenameto=dol_sanitizeFileName(GETPOST('renamefileto','alpha'));
|
$filenameto=dol_sanitizeFileName(GETPOST('renamefileto','alpha'), '_', 0); // Do not remove accents
|
||||||
|
|
||||||
// Security:
|
// Security:
|
||||||
// Disallow file with some extensions. We rename them.
|
// Disallow file with some extensions. We rename them.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user