diff options
Diffstat (limited to 'views/default/core/friends/collections.php')
-rw-r--r-- | views/default/core/friends/collections.php | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/views/default/core/friends/collections.php b/views/default/core/friends/collections.php new file mode 100644 index 000000000..c6ee082c8 --- /dev/null +++ b/views/default/core/friends/collections.php @@ -0,0 +1,39 @@ +<?php +/** + * Elgg friends collections + * Lists a user's friends collections + * + * @package Elgg + * @subpackage Core + * + * @uses $vars['collections'] The array of friends collections + */ + +if (is_array($vars['collections']) && sizeof($vars['collections'])) { + echo "<ul id=\"friends_collections_accordian\">"; + + $friendspicker = 0; + foreach ($vars['collections'] as $collection) { + $friendspicker++; + echo elgg_view('core/friends/collection', array( + 'collection' => $collection, + 'friendspicker' => $friendspicker, + )); + } + + echo "</ul>"; + +} else { + echo elgg_echo("friends:nocollections"); +} + +?> +<?php //@todo JS 1.8: no ?> +<script> +$(function(){ + $('#friends_collections_accordian h2').click(function () { + $(this.parentNode).children("[class=friends-picker-main-wrapper]").slideToggle("fast"); + //return false; + }); +}); +</script> |