Fixed a bug by which profile names that began with lowercase letters weren't recognized if there were no other usernames beginning with that letter that were upercase.

svn path=/trunk/boinc/; revision=2101
This commit is contained in:
David Anderson 2003-08-14 01:18:09 +00:00
parent 1a75ab2973
commit efc3780e8d
1 changed files with 36 additions and 36 deletions

View File

@ -158,7 +158,8 @@ function build_alpha_pages() {
$row2 = mysql_fetch_assoc($result2);
if ($row2['name']) {
$members[$row2['name'][0]][] = $row2['id'];
$name = ltrim($row2['name']);
$members[strtoupper($name[0])][] = $row2['id'];
$numIds++;
}
}
@ -171,8 +172,7 @@ function build_alpha_pages() {
$letters = array_keys($members);
foreach ($letters as $letter) {
// TODO: Make sure array indexing is not case sensitive.
$letter = strtoupper($letter);
// NOTE: Array indexing is case sensitive.
$filePath = "../html_user/" . PROFILE_PATH;
build_profile_pages($members[$letter], "User Profiles - Names beginning with $letter", "Names beginning with $letter", 5, 2, $filePath, "profile_$letter");
}