diff options
author | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-02-20 17:49:05 +0000 |
---|---|---|
committer | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-02-20 17:49:05 +0000 |
commit | 2447aa071c65e99f9981059637054734f3951e0b (patch) | |
tree | 40f45e609e369a952be2767990309d13f26f03e7 /mod/notifications/views/default | |
parent | e0c1dc8ec7ff8ce94241d0150f197ba3710cda15 (diff) | |
download | elgg-2447aa071c65e99f9981059637054734f3951e0b.tar.gz elgg-2447aa071c65e99f9981059637054734f3951e0b.tar.bz2 |
The friends picker now highlights tabs when creating a collection if a user is present there. Also, the separate friends picker in the notification plugin is also now internationalised.
git-svn-id: https://code.elgg.org/elgg/trunk@2872 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/notifications/views/default')
-rw-r--r-- | mod/notifications/views/default/notifications/subscriptions/forminternals.php | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/mod/notifications/views/default/notifications/subscriptions/forminternals.php b/mod/notifications/views/default/notifications/subscriptions/forminternals.php index ca28fc72a..eb35b5ba0 100644 --- a/mod/notifications/views/default/notifications/subscriptions/forminternals.php +++ b/mod/notifications/views/default/notifications/subscriptions/forminternals.php @@ -23,7 +23,8 @@ // Let the system know that the friends picker is in use global $pickerinuse; - $pickerinuse = true; + $pickerinuse = true;
+ $chararray = elgg_echo('friendspicker:chararray'); // Initialise internalname if (!isset($vars['internalname'])) { @@ -74,8 +75,8 @@ foreach($friends as $user) { $letter = strtoupper(substr($user->name,0,1)); - if ($letter >= "0" && $letter <= "9") { - $letter = "0"; + if (!substr_count($chararray,$letter)) { + $letter = "*"; } if (!isset($users[$letter])) { $users[$letter] = array(); @@ -147,7 +148,9 @@ <?php // Initialise letters - $letter = 'A'; + $letter = substr($chararray,0,1);
+ $letpos = 0;
+ $chararray .= '*'; while (1 == 1) { ?> <div class="panel" title="<?php echo $letter; ?>"> @@ -234,8 +237,9 @@ END; </div> </div> <?php - if ($letter == 'Z') break; - $letter++; + $letpos++;
+ if ($letpos == strlen($chararray)) break;
+ $letter = substr($chararray,$letpos,1); } ?> |