aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/views/default
diff options
context:
space:
mode:
Diffstat (limited to 'mod/groups/views/default')
-rw-r--r--mod/groups/views/default/groups/featured.php9
-rw-r--r--mod/groups/views/default/groups/find.php21
-rw-r--r--mod/groups/views/default/groups/group_sort_menu.php28
-rw-r--r--mod/groups/views/default/groups/grouplisting.php12
4 files changed, 68 insertions, 2 deletions
diff --git a/mod/groups/views/default/groups/featured.php b/mod/groups/views/default/groups/featured.php
new file mode 100644
index 000000000..ab7691a0b
--- /dev/null
+++ b/mod/groups/views/default/groups/featured.php
@@ -0,0 +1,9 @@
+<?php
+
+ /**
+ * This view will display featured groups - these are set by admin
+ **/
+
+?>
+
+<h3>Featured groups</h3> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/find.php b/mod/groups/views/default/groups/find.php
new file mode 100644
index 000000000..3dc37dac0
--- /dev/null
+++ b/mod/groups/views/default/groups/find.php
@@ -0,0 +1,21 @@
+<?php
+
+ /**
+ * A simlpe group search by tag view
+ **/
+
+?>
+<div class="group_search">
+<h3><?php echo elgg_echo('groups:searchtag'); ?></h3>
+<form id="searchform" action="" method="get">
+ <input type="text" name="group_find" value="Search" onclick="if (this.value=='Search') { this.value='' }" class="search_input" />
+ <input type="submit" value="<?php echo elgg_echo('go'); ?>" class="search_submit_button" />
+</form>
+</div>
+<div class="user_groups_link">
+<?php
+ if(isloggedin())
+ echo "<p><a href=\"{$vars['url']}pg/groups/member/{$_SESSION['user']->username}\">". elgg_echo('groups:yours') ."</a></p>";
+
+?>
+</div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/group_sort_menu.php b/mod/groups/views/default/groups/group_sort_menu.php
new file mode 100644
index 000000000..957094ee6
--- /dev/null
+++ b/mod/groups/views/default/groups/group_sort_menu.php
@@ -0,0 +1,28 @@
+<?php
+
+ /**
+ * A simple view to provide the user with group filters and the number of group on the site
+ **/
+
+ $num_groups = $vars['count'];
+ if(!$num_groups)
+ $num_groups = 0;
+
+ $filter = $vars['filter'];
+
+ //url
+ $url = $vars['url'] . "pg/groups/world/";
+
+?>
+<div id="elgg_horizontal_tabbed_nav">
+<ul>
+ <li <?php if($filter == "newest") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=newest"><?php echo elgg_echo('newest'); ?></a></li>
+ <li <?php if($filter == "pop") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=pop"><?php echo elgg_echo('popular'); ?></a></li>
+ <li <?php if($filter == "active") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=active"><?php echo elgg_echo('groups:latestdiscussion'); ?></a></li>
+</ul>
+</div>
+<div class="group_count">
+ <?php
+ echo $num_groups . " " . elgg_echo("groups:count");
+ ?>
+</div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/grouplisting.php b/mod/groups/views/default/groups/grouplisting.php
index 3d0e1ce34..8d7e3c6d8 100644
--- a/mod/groups/views/default/groups/grouplisting.php
+++ b/mod/groups/views/default/groups/grouplisting.php
@@ -17,9 +17,17 @@
'size' => 'small',
)
);
-
+
+ //get the membership type
+ $membership = $vars['entity']->membership;
+ if($membership == 2)
+ $mem = elgg_echo("groups:open");
+ else
+ $mem = elgg_echo("groups:closed");
+
+ $info .= "<div style=\"float:right;\">" . $mem . " / " . elgg_echo("groups:member") . " (" . get_group_members($vars['entity']->guid, 10, 0, 0, true) . ")</div>";
$info .= "<p><b><a href=\"" . $vars['entity']->getUrl() . "\">" . $vars['entity']->name . "</a></b></p>";
- $info .= "<p class=\"owner_timestamp\">" . $vars['entity']->briefdescription . "</p>";
+ $info .= "<p class=\"owner_timestamp\">" . $vars['entity']->description . "</p>";
// num users, last activity, owner etc