aboutsummaryrefslogtreecommitdiff
path: root/views/default/friends/picker.php
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-02-20 17:49:05 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-02-20 17:49:05 +0000
commit2447aa071c65e99f9981059637054734f3951e0b (patch)
tree40f45e609e369a952be2767990309d13f26f03e7 /views/default/friends/picker.php
parente0c1dc8ec7ff8ce94241d0150f197ba3710cda15 (diff)
downloadelgg-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 'views/default/friends/picker.php')
-rw-r--r--views/default/friends/picker.php20
1 files changed, 17 insertions, 3 deletions
diff --git a/views/default/friends/picker.php b/views/default/friends/picker.php
index 877a07782..5b7227c99 100644
--- a/views/default/friends/picker.php
+++ b/views/default/friends/picker.php
@@ -24,7 +24,11 @@
$internalname = "friend";
} else {
$internalname = $vars['internalname'];
- }
+ }
+
+ // Are we highlighting default or all?
+ if (empty($vars['highlight'])) $vars['highlight'] = 'default';
+ if ($vars['highlight'] != 'all') $vars['highlight'] = 'default';
// Initialise values
if (!isset($vars['value'])) {
@@ -165,10 +169,20 @@
//echo "<p>" . $user->name . "</p>";
$label = elgg_view("profile/icon",array('entity' => $friend, 'size' => 'tiny', 'override' => true));
- $options[$label] = $friend->getGUID();
+ $options[$label] = $friend->getGUID();
+
+ if ($vars['highlight'] == 'all'
+ && !in_array($letter,$activeletters)) {
+ $activeletters[] = $letter;
+ }
+
+
if (in_array($friend->getGUID(),$vars['value'])) {
$checked = "checked = \"checked\"";
- if (!in_array($letter,$activeletters))
+ if (
+ !in_array($letter,$activeletters)
+ && $vars['highlight'] == 'default'
+ )
$activeletters[] = $letter;
} else {
$checked = "";