mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-04-30 18:42:43 +02:00
upgrade jquery to 1.7.1
mouseout on index drop down bozes improved multisize center of interest git-svn-id: http://piwigo.org/svn/trunk@13052 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -202,18 +202,18 @@ SELECT
|
||||
}
|
||||
|
||||
$ok = true;
|
||||
if (!isset($conf['never_delete_originals']))
|
||||
{
|
||||
foreach ($files as $path)
|
||||
{
|
||||
if (is_file($path) and !unlink($path))
|
||||
{
|
||||
$ok = false;
|
||||
trigger_error('"'.$path.'" cannot be removed', E_USER_WARNING);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!isset($conf['never_delete_originals']))
|
||||
{
|
||||
foreach ($files as $path)
|
||||
{
|
||||
if (is_file($path) and !unlink($path))
|
||||
{
|
||||
$ok = false;
|
||||
trigger_error('"'.$path.'" cannot be removed', E_USER_WARNING);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($ok)
|
||||
{
|
||||
@@ -2306,7 +2306,7 @@ function clear_derivative_cache_rec($path, $pattern)
|
||||
}
|
||||
}
|
||||
|
||||
function delete_element_derivatives($infos)
|
||||
function delete_element_derivatives($infos, $type='all')
|
||||
{
|
||||
$path = $infos['path'];
|
||||
if (!empty($infos['representative_ext']))
|
||||
@@ -2317,8 +2317,16 @@ function delete_element_derivatives($infos)
|
||||
{
|
||||
$path = substr($path, 3);
|
||||
}
|
||||
$dot = strpos($path, '.');
|
||||
$path = substr_replace($path, '-*', $dot, 0);
|
||||
$dot = strrpos($path, '.');
|
||||
if ($type=='all')
|
||||
{
|
||||
$pattern = '-*';
|
||||
}
|
||||
else
|
||||
{
|
||||
$pattern = '-'.derivative_to_url($type).'*';
|
||||
}
|
||||
$path = substr_replace($path, $pattern, $dot, 0);
|
||||
foreach( glob(PHPWG_ROOT_PATH.PWG_DERIVATIVE_DIR.$path) as $file)
|
||||
{
|
||||
@unlink($file);
|
||||
|
||||
Reference in New Issue
Block a user