Changeset 2144 for trunk/admin.php


Ignore:
Timestamp:
Oct 19, 2007, 4:05:21 AM (17 years ago)
Author:
rvelices
Message:

merge r 2143 from branch-1_7 to trunk
feature 765: Sort alphabetically the admin plugin menus and plugin list

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin.php

    r2107 r2144  
    116116
    117117//---------------------------------------------------------------- plugin menus
    118 $plugin_menu_links = array(
     118$plugin_menu_links = trigger_event('get_admin_plugin_menu_links', array() );
     119
     120function UC_name_compare($a, $b)
     121{
     122  return strcmp(strtolower($a['NAME']), strtolower($b['NAME']));
     123}
     124usort($plugin_menu_links, 'UC_name_compare');
     125
     126array_unshift($plugin_menu_links,
    119127    array(
    120128      'NAME' => l10n('admin'),
     
    122130    )
    123131  );
    124 $plugin_menu_links = trigger_event('get_admin_plugin_menu_links',
    125   $plugin_menu_links );
     132
    126133foreach ($plugin_menu_links as $menu_item)
    127134{
Note: See TracChangeset for help on using the changeset viewer.