mirror of
https://github.com/Piwigo/Piwigo.git
synced 2025-04-27 19:59:56 +03:00
Bug 703: Authorization system in Cat management works now with well ordered lists
(Minor: Admin theme changes) git-svn-id: http://piwigo.org/svn/trunk@2349 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
parent
6ee69cf39c
commit
069748aa91
5 changed files with 23 additions and 3 deletions
|
@ -731,4 +731,21 @@ function render_category_literal_description($desc)
|
|||
{
|
||||
return strip_tags($desc, '<span><p><a><br><b><i><small><big><strong><em>');
|
||||
}
|
||||
|
||||
/** returns the argument_ids array with new sequenced keys based on related
|
||||
* names. Sequence is not case sensitive.
|
||||
* Warning: By definition, this function breaks original keys
|
||||
*/
|
||||
function order_by_name($element_ids,$name)
|
||||
{
|
||||
$ordered_element_ids = array();
|
||||
foreach ($element_ids as $k_id => $element_id)
|
||||
{
|
||||
$key = strtolower($name[$element_id]) .'-'. $name[$element_id] .'-'. $k_id;
|
||||
$ordered_element_ids[$key] = $element_id;
|
||||
}
|
||||
ksort($ordered_element_ids);
|
||||
return $ordered_element_ids;
|
||||
}
|
||||
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue