Project

General

Profile

« Previous | Next » 

Revision 384

Added by Matthias over 17 years ago

Added List sorting in admin area (thanks to rsmith)

View differences:

index.php
139 139

  
140 140
// Insert language values
141 141
$template->set_block('main_block', 'language_list_block', 'language_list');
142
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'language'");
142
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'language' order by directory");
143 143
if($result->numRows() > 0) {
144 144
	while ($addon = $result->fetchRow()) {
145 145
		// Insert code and name
......
228 228

  
229 229
// Insert templates
230 230
$template->set_block('main_block', 'template_list_block', 'template_list');
231
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'template'");
231
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'template' order by name");
232 232
if($result->numRows() > 0) {
233 233
	while($addon = $result->fetchRow()) {
234 234
		$template->set_var('FILE', $addon['directory']);
......
264 264
if($search_template == '') { $selected = ' selected'; } else { $selected = ''; }
265 265
$template->set_var(array('FILE' => '', 'NAME' => $TEXT['SYSTEM_DEFAULT'], 'SELECTED' => $selected));
266 266
$template->parse('search_template_list', 'search_template_list_block', true);
267
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'template'");
267
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'template' order by name");
268 268
if($result->numRows() > 0) {
269 269
	while($addon = $result->fetchRow()) {
270 270
		$template->set_var('FILE', $addon['directory']);

Also available in: Unified diff