mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-06-02 04:15:05 +02:00
bug 560: merge r1561 to trunk - url issue when $conf['picture_url_style']='file' and
filename is numeric or numeric followed by - git-svn-id: http://piwigo.org/svn/trunk@1562 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -213,16 +213,15 @@ function make_picture_url($params)
|
||||
}
|
||||
break;
|
||||
case 'file':
|
||||
if ( isset($params['image_file'])
|
||||
and !is_numeric($params['image_file']) )
|
||||
if ( isset($params['image_file']) )
|
||||
{
|
||||
$url .= get_filename_wo_extension($params['image_file']);
|
||||
$fname_wo_ext = get_filename_wo_extension($params['image_file']);
|
||||
if (! preg_match('/^\d+(-|$)/', $fname_wo_ext) )
|
||||
{
|
||||
$url .= $fname_wo_ext;
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$url .= $params['image_id'];
|
||||
}
|
||||
break;
|
||||
default:
|
||||
$url .= $params['image_id'];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user