2
0
forked from Wavyzz/dolibarr

Fix deletion of files that contains __

This commit is contained in:
Laurent Destailleur
2017-11-06 17:54:18 +01:00
parent 825ceeaa8d
commit bc9b816719
2 changed files with 5 additions and 4 deletions

View File

@@ -56,7 +56,7 @@ if ($action == 'confirm_deletefile' && $confirm == 'yes')
{
if ($object->id)
{
$urlfile = GETPOST('urlfile', 'alpha'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
$urlfile = GETPOST('urlfile', 'alpha', 0, null, null, 1); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
if (GETPOST('section', 'alpha')) $file = $upload_dir . "/" . $urlfile; // For a delete of GED module urlfile contains full path from upload_dir
else // For documents pages, upload_dir contains already path to file from module dir, so we clean path into urlfile.
{