Skip to content

Commit

Permalink
Better way of sorting countries
Browse files Browse the repository at this point in the history
  • Loading branch information
martin committed Sep 22, 2002
1 parent 096dc19 commit 7c3cf7f
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions admin/user.php
Expand Up @@ -150,10 +150,13 @@
}
if ($sort == "country") { // Need to resort by full country name, not code
foreach ($users as $user) {
$susers[$user->country] = $user;
$susers[$user->id] = $user->country;
}
$users = $susers;
ksort($users);
asort($susers);
foreach ($susers as $key => $value) {
$nusers[] = $users[$key];
}
$users = $nusers;
}

print_heading(get_string("chooseuser"));
Expand Down

0 comments on commit 7c3cf7f

Please sign in to comment.