Ticket #2412: alphabetical_plugins.diff
File alphabetical_plugins.diff, 743 bytes (added by , 18 years ago) |
---|
-
plugins.php
88 88 <?php 89 89 $style = ''; 90 90 91 function sort_plugins($plug1, $plug2) { 92 return strnatcasecmp($plug1['Name'], $plug2['Name']); 91 // Sort plugins by plugin name 92 foreach ($plugins as $plugin_file => $plugin_data) { 93 $plugin_names[] = $plugin_data['Name']; 93 94 } 94 95 uksort($plugins, 'sort_plugins');95 $plugin_names = array_map('strtolower', $plugin_names); 96 array_multisort($plugin_names, SORT_ASC, $plugins); 96 97 97 98 foreach($plugins as $plugin_file => $plugin_data) { 98 99 $style = ('class="alternate"' == $style|| 'class="alternate active"' == $style) ? '' : 'alternate';