Merged revision(s) 26972, 26998 from trunk:

replace more preg_replace callback
........
remove *_version_compare methods in languages & plugins & themes classes, unused and outdated (preg_replace /e modifier)

git-svn-id: http://piwigo.org/svn/branches/2.6@26999 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
mistic100
2014-01-27 18:05:04 +00:00
parent 46c2cb6b5f
commit 6fcc5f10df
6 changed files with 32 additions and 53 deletions
-10
View File
@@ -689,16 +689,6 @@ SELECT
/**
* Sort functions
*/
function theme_version_compare($a, $b)
{
$pattern = array('/([a-z])/ei', '/\.+/', '/\.\Z|\A\./');
$replacement = array( "'.'.intval('\\1', 36).'.'", '.', '');
$array = preg_replace($pattern, $replacement, array($a, $b));
return version_compare($array[0], $array[1], '>=');
}
function extension_revision_compare($a, $b)
{
if ($a['revision_date'] < $b['revision_date']) return 1;