aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xjavascript/friendsPickerv1.js10
-rw-r--r--views/default/friends/picker.php9
2 files changed, 12 insertions, 7 deletions
diff --git a/javascript/friendsPickerv1.js b/javascript/friendsPickerv1.js
index 3ecf4bfc3..843b2ff9d 100755
--- a/javascript/friendsPickerv1.js
+++ b/javascript/friendsPickerv1.js
@@ -89,11 +89,11 @@ jQuery.fn.friendsPicker = function(settings) {
});
// manually add class to corresponding tab for panels that have content - needs to be automated eventually
- $("div#friendsPickerNavigation" + j + " li.tab3 a").addClass("tabHasContent");
- $("div#friendsPickerNavigation" + j + " li.tab6 a").addClass("tabHasContent");
- $("div#friendsPickerNavigation" + j + " li.tab9 a").addClass("tabHasContent");
- $("div#friendsPickerNavigation" + j + " li.tab17 a").addClass("tabHasContent");
- $("div#friendsPickerNavigation" + j + " li.tab22 a").addClass("tabHasContent");
+ //$("div#friendsPickerNavigation" + j + " li.tab3 a").addClass("tabHasContent");
+ //$("div#friendsPickerNavigation" + j + " li.tab6 a").addClass("tabHasContent");
+ //$("div#friendsPickerNavigation" + j + " li.tab9 a").addClass("tabHasContent");
+ //$("div#friendsPickerNavigation" + j + " li.tab17 a").addClass("tabHasContent");
+ //$("div#friendsPickerNavigation" + j + " li.tab22 a").addClass("tabHasContent");
// generate link to 'all friends in collection' - removed for now
//$("div#friendsPickerNavigation" + j).append("<div class='friendsPickerNavigationAll'><a href='#' >Collection members<\/a></div><br />");
diff --git a/views/default/friends/picker.php b/views/default/friends/picker.php
index c545a643a..a226f24e1 100644
--- a/views/default/friends/picker.php
+++ b/views/default/friends/picker.php
@@ -132,15 +132,20 @@
});
</script>
<script>
+ jQuery(window).bind("load", function() {
// manually add class to corresponding tab for panels that have content - needs to be automated eventually
<?php
-
if (sizeof($users) > 0)
+ $chararray = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
foreach($users as $letter => $gumph) {
+ $tab = strpos($chararray, $letter) + 1;
+ if (is_array($gumph) && sizeof($gumph)) {
?>
- $("div#friendsPickerNavigation" + j + " li.tab3 <?php echo $letter; ?>").addClass("tabHasContent");
+ $("div#friendsPickerNavigation<?php echo $friendspicker - 1; ?> li.tab<?php echo $tab; ?> a").addClass("tabHasContent");
<?php
+ }
}
?>
+ });
</script> \ No newline at end of file