aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/views/default/groups
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-03 17:53:05 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-03 17:53:05 +0000
commit4766f36a4d74924f21ff329c4318ce4e069ffa04 (patch)
tree969b84632f2a8b0db79788a8a6db8e41d63e5cb4 /mod/groups/views/default/groups
parent57a217fd6b708844407486046a1faa23b46cac08 (diff)
downloadelgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.gz
elgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.bz2
Pulled in the interface changes.
git-svn-id: http://code.elgg.org/elgg/trunk@5257 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/groups/views/default/groups')
-rw-r--r--mod/groups/views/default/groups/closedmembership.php15
-rw-r--r--mod/groups/views/default/groups/contentwrapper.php5
-rw-r--r--mod/groups/views/default/groups/css.php401
-rw-r--r--mod/groups/views/default/groups/featured.php29
-rw-r--r--mod/groups/views/default/groups/find.php20
-rw-r--r--mod/groups/views/default/groups/forum_latest.php38
-rw-r--r--mod/groups/views/default/groups/group_sort_menu.php28
-rw-r--r--mod/groups/views/default/groups/groupgallery.php25
-rw-r--r--mod/groups/views/default/groups/grouplisting.php49
-rw-r--r--mod/groups/views/default/groups/groupprofile.php102
-rw-r--r--mod/groups/views/default/groups/icon.php48
-rw-r--r--mod/groups/views/default/groups/invitationrequests.php44
-rw-r--r--mod/groups/views/default/groups/members.php30
-rw-r--r--mod/groups/views/default/groups/membershiprequests.php44
-rw-r--r--mod/groups/views/default/groups/profileitems.php28
-rw-r--r--mod/groups/views/default/groups/side_menu.php10
16 files changed, 916 insertions, 0 deletions
diff --git a/mod/groups/views/default/groups/closedmembership.php b/mod/groups/views/default/groups/closedmembership.php
new file mode 100644
index 000000000..34e4169eb
--- /dev/null
+++ b/mod/groups/views/default/groups/closedmembership.php
@@ -0,0 +1,15 @@
+<?php
+ /**
+ * Elgg groups plugin full profile view (for a closed group you haven't joined).
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+?>
+<div id="groups_closed_membership">
+ <p><?php echo elgg_echo('groups:closedgroup'); ?></p>
+</div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/contentwrapper.php b/mod/groups/views/default/groups/contentwrapper.php
new file mode 100644
index 000000000..e11d3d09a
--- /dev/null
+++ b/mod/groups/views/default/groups/contentwrapper.php
@@ -0,0 +1,5 @@
+<div class='contentWrapper groups'><?php
+
+ echo $vars['body'];
+
+?></div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/css.php b/mod/groups/views/default/groups/css.php
new file mode 100644
index 000000000..bc8d2bfc0
--- /dev/null
+++ b/mod/groups/views/default/groups/css.php
@@ -0,0 +1,401 @@
+<?php
+
+ /**
+ * Elgg Groups css
+ *
+ * @package groups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd <info@elgg.com>
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+?>
+
+#content_area_group_title h2 {
+ color:#0054A7;
+ font-size:1.35em;
+ line-height:1.2em;
+ margin:0 0 0 8px;
+ padding:5px;
+}
+#topic_posts #content_area_group_title h2 {
+ margin:0 0 0 0;
+}
+
+#two_column_left_sidebar_maincontent #owner_block_content {
+ margin:0 0 10px 0 !important;
+}
+
+#groups_info_column_left {
+ width:435px;
+ margin-left:230px;
+ margin-right:10px;
+}
+
+#groups_info_column_left .odd {
+ background:#E9E9E9;
+ -webkit-border-radius: 5px;
+ -moz-border-radius: 5px;
+}
+#groups_info_column_left .even {
+ background:#E9E9E9;
+ -webkit-border-radius: 5px;
+ -moz-border-radius: 5px;
+}
+#groups_info_column_left p {
+ margin:0 0 7px 0;
+ padding:2px 4px;
+}
+
+#groups_info_column_right {
+ float:left;
+ width:230px;
+ margin:0 0 0 10px;
+}
+#groups_info_wide p {
+ text-align: right;
+ padding-right:10px;
+}
+#group_stats {
+ width:190px;
+ background: #e9e9e9;
+ padding:5px;
+ margin:10px 0 20px 0;
+ -webkit-border-radius: 5px;
+ -moz-border-radius: 5px;
+}
+#group_stats p {
+ margin:0;
+}
+#group_members {
+ margin:10px;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+ background: white;
+}
+
+#right_column {
+ clear:left;
+ float:right;
+ width:340px;
+ margin:0 10px 0 0;
+}
+#left_column {
+ width:340px;
+ float:left;
+ margin:0 10px 0 10px;
+
+}
+/* IE 6 fixes */
+* html #left_column {
+ margin:0 0 0 5px;
+}
+* html #right_column {
+ margin:0 5px 0 0;
+}
+
+#group_members h2,
+#right_column h2,
+#left_column h2,
+#fullcolumn h2 {
+ margin:0 0 10px 0;
+ padding:5px;
+ color:#0054A7;
+ font-size:1.25em;
+ line-height:1.2em;
+}
+#fullcolumn .contentWrapper {
+ margin:0 10px 20px 10px;
+ padding:0 0 5px;
+}
+
+.member_icon {
+ margin:0 0 6px 6px;
+ float:left;
+}
+
+/* IE6 */
+* html #topic_post_tbl { width:676px !important;}
+
+/* all browsers - force tinyMCE on edit comments to be full-width */
+.edit_forum_comments .defaultSkin table.mceLayout {
+ width: 636px !important;
+}
+
+/* topics overview page */
+#forum_topics {
+ padding:10px;
+ margin:0 10px 0 10px;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+/* topics individual view page */
+#topic_posts {
+ margin:0 10px 5px 10px;
+}
+#topic_posts #pages_breadcrumbs {
+ margin:2px 0 0 0px;
+}
+#topic_posts form {
+ padding:10px;
+ margin:30px 0 0 0;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+.topic_post {
+ padding:10px;
+ margin:0 0 5px 0;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+.topic_post .post_icon {
+ float:left;
+ margin:0 8px 4px 0;
+}
+.topic_post h2 {
+ margin-bottom:20px;
+}
+.topic_post p.topic-post-menu {
+ margin:0;
+}
+.topic_post p.topic-post-menu a.collapsibleboxlink {
+ padding-left:10px;
+}
+.topic_post table, .topic_post td {
+ border:none;
+}
+
+/* group latest discussions widget */
+#latest_discussion_widget {
+ margin:0 0 20px 0;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+/* group files widget */
+#filerepo_widget_layout {
+ margin:0 0 20px 0;
+ padding: 0 0 5px 0;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+/* group pages widget */
+#group_pages_widget {
+ margin:0 0 20px 0;
+ padding: 0 0 5px 0;
+ background:white;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+#group_pages_widget .search_listing {
+ border: 2px solid #cccccc;
+}
+#right_column .filerepo_widget_singleitem {
+ background: #dedede !important;
+ margin:0 10px 5px 10px;
+}
+#left_column .filerepo_widget_singleitem {
+ background: #dedede !important;
+ margin:0 10px 5px 10px;
+}
+.forum_latest {
+ margin:0 10px 5px 10px;
+ background: #dedede;
+ padding:5px;
+ -webkit-border-radius: 4px;
+ -moz-border-radius: 4px;
+}
+.forum_latest:hover {
+
+}
+.forum_latest .topic_owner_icon {
+ float:left;
+}
+.forum_latest .topic_title {
+ margin-left:35px;
+}
+.forum_latest .topic_title p {
+ line-height: 1.0em;
+ padding:0;
+ margin:0;
+ font-weight: bold;
+}
+.forum_latest p.topic_replies {
+ padding:3px 0 0 0;
+ margin:0;
+ color:#666666;
+}
+.add_topic {
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+ background:white;
+ margin:5px 10px;
+ padding:10px 10px 10px 6px;
+}
+
+a.add_topic_button {
+ font: 12px/100% Arial, Helvetica, sans-serif;
+ font-weight: bold;
+ color: white;
+ background:#4690d6;
+ border:none;
+ -webkit-border-radius: 5px;
+ -moz-border-radius: 5px;
+ width: auto;
+ height: auto;
+ padding: 3px 6px 3px 6px;
+ margin:0;
+ cursor: pointer;
+}
+a.add_topic_button:hover {
+ background: #0054a7;
+ color:white;
+ text-decoration: none;
+}
+
+
+
+/* latest discussion listing */
+.latest_discussion_info {
+ float:right;
+ width:300px;
+ text-align: right;
+ margin-left: 10px;
+}
+.groups .search_listing br {
+ height:0;
+ line-height:0;
+}
+span.timestamp {
+ color:#666666;
+ font-size: 90%;
+}
+.latest_discussion_info .timestamp {
+ font-size: 0.85em;
+}
+/* new groups page */
+.groups .search_listing {
+ border:2px solid #cccccc;
+ margin:0 0 5px 0;
+}
+.groups .search_listing:hover {
+ background:#dedede;
+}
+.groups .group_count {
+ font-weight: bold;
+ color: #666666;
+ margin:0 0 5px 4px;
+}
+.groups .search_listing_info {
+ color:#666666;
+}
+.groupdetails {
+ float:right;
+}
+.groupdetails p {
+ margin:0;
+ padding:0;
+ line-height: 1.1em;
+ text-align: right;
+}
+#groups_closed_membership {
+ margin:0 10px 20px 10px;
+ padding: 3px 5px 5px 5px;
+ background:#bbdaf7;
+ -webkit-border-radius: 8px;
+ -moz-border-radius: 8px;
+}
+#groups_closed_membership p {
+ margin:0;
+}
+
+/* groups membership widget */
+.groupmembershipwidget .contentWrapper {
+ margin:0 10px 5px 10px;
+}
+.groupmembershipwidget .contentWrapper .groupicon {
+ float:left;
+ margin:0 10px 0 0;
+}
+.groupmembershipwidget .search_listing_info p {
+ color: #666666;
+}
+.groupmembershipwidget .search_listing_info span {
+ font-weight: bold;
+}
+
+/* groups sidebar */
+.featuredgroups .contentWrapper {
+ margin:0 0 10px 0;
+}
+.featuredgroups .contentWrapper .groupicon {
+ float:left;
+ margin:0 10px 0 0;
+}
+.featuredgroups .contentWrapper p {
+ margin: 0;
+ line-height: 1.2em;
+ color:#666666;
+}
+.featuredgroups .contentWrapper span {
+ font-weight: bold;
+}
+#groupssearchform {
+ border-bottom: 1px solid #cccccc;
+ margin-bottom: 10px;
+}
+#groupssearchform input[type="submit"] {
+ padding:2px;
+ height:auto;
+ margin:4px 0 5px 0;
+}
+.sidebarBox #owner_block_submenu {
+ margin:5px 0 0 0;
+}
+
+/* delete post */
+.delete_discussion {
+
+}
+.delete_discussion a {
+ display:block;
+ float:right;
+ cursor: pointer;
+ width:14px;
+ height:14px;
+ margin:0;
+ background: url("<?php echo $vars['url']; ?>_graphics/icon_customise_remove.png") no-repeat 0 0;
+}
+.delete_discussion a:hover {
+ background-position: 0 -16px;
+ text-decoration: none;
+}
+/* IE6 */
+* html .delete_discussion a { font-size: 1px; }
+/* IE7 */
+*:first-child+html .delete_discussion a { font-size: 1px; }
+
+/* delete group button */
+#delete_group_option input[type="submit"] {
+ background:#dedede;
+ border-color:#dedede;
+ color:#333333;
+ margin:0;
+ float:right;
+ clear:both;
+}
+#delete_group_option input[type="submit"]:hover {
+ background:red;
+ border-color:red;
+ color:white;
+}
+
+#groupsearchform .search_input {
+ width:176px;
+}
+
diff --git a/mod/groups/views/default/groups/featured.php b/mod/groups/views/default/groups/featured.php
new file mode 100644
index 000000000..6e85bf5d8
--- /dev/null
+++ b/mod/groups/views/default/groups/featured.php
@@ -0,0 +1,29 @@
+<?php
+
+ /**
+ * This view will display featured groups - these are set by admin
+ **/
+
+
+?>
+<div class="sidebarBox featuredgroups">
+<h3><?php echo elgg_echo("groups:featured"); ?></h3>
+
+<?php
+ if($vars['featured']){
+
+ foreach($vars['featured'] as $group){
+ $icon = elgg_view(
+ "groups/icon", array(
+ 'entity' => $group,
+ 'size' => 'small',
+ )
+ );
+
+ echo "<div class=\"contentWrapper\">" . $icon . " <p><span>" . $group->name . "</span><br />";
+ echo $group->briefdescription . "</p><div class=\"clearfloat\"></div></div>";
+
+ }
+ }
+?>
+</div> \ 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..671d618bc
--- /dev/null
+++ b/mod/groups/views/default/groups/find.php
@@ -0,0 +1,20 @@
+<?php
+
+ /**
+ * A simple group search by tag view
+ **/
+
+$tag_string = elgg_echo('groups:search:tags');
+
+?>
+<div class="sidebarBox">
+<h3><?php echo elgg_echo('groups:searchtag'); ?></h3>
+<form id="groupsearchform" action="<?php echo $vars['url']; ?>pg/search/" method="get">
+ <input type="text" name="tag" value="<?php echo $tag_string; ?>" onclick="if (this.value=='<?php echo $tag_string; ?>') { this.value='' }" class="search_input" />
+ <input type="hidden" name="entity_type" value="group" />
+ <input type="hidden" name="subtype" value="" />
+ <input type="hidden" name="tagtype" value="" />
+ <input type="hidden" name="owner_guid" value="0" />
+ <input type="submit" value="<?php echo elgg_echo('go'); ?>" />
+</form>
+</div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/forum_latest.php b/mod/groups/views/default/groups/forum_latest.php
new file mode 100644
index 000000000..6baa8a575
--- /dev/null
+++ b/mod/groups/views/default/groups/forum_latest.php
@@ -0,0 +1,38 @@
+<?php
+
+ // Latest forum discussion for the group home page
+
+ //check to make sure this group forum has been activated
+ if($vars['entity']->forum_enable != 'no'){
+
+?>
+
+<div class="contentWrapper">
+<h2><?php echo elgg_echo('groups:latestdiscussion'); ?></h2>
+<?php
+
+ $forum = elgg_get_entities_from_annotations(array('types' => 'object', 'subtypes' => 'groupforumtopic', 'annotation_names' => 'group_topic_post', 'container_guid' => $vars['entity']->guid, 'limit' => 4, 'order_by' => 'maxtime desc'));
+
+ if($forum){
+ foreach($forum as $f){
+
+ $count_annotations = $f->countAnnotations("group_topic_post");
+
+ echo "<div class=\"forum_latest\">";
+ echo "<div class=\"topic_owner_icon\">" . elgg_view('profile/icon',array('entity' => $f->getOwnerEntity(), 'size' => 'tiny', 'override' => true)) . "</div>";
+ echo "<div class=\"topic_title\"><p><a href=\"{$vars['url']}mod/groups/topicposts.php?topic={$f->guid}&group_guid={$vars['entity']->guid}\">" . $f->title . "</a></p> <p class=\"topic_replies\"><small>".elgg_echo('groups:posts').": " . $count_annotations . "</small></p></div>";
+
+ echo "</div>";
+
+ }
+ } else {
+ echo "<div class=\"forum_latest\">";
+ echo elgg_echo("grouptopic:notcreated");
+ echo "</div>";
+ }
+?>
+<div class="clearfloat" /></div>
+</div>
+<?php
+ }//end of forum active check
+?> \ 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..7314507e0
--- /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 == "active") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=active"><?php echo elgg_echo('groups:latestdiscussion'); ?></a></li>
+ <li <?php if($filter == "newest") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=newest"><?php echo elgg_echo('groups:newest'); ?></a></li>
+ <li <?php if($filter == "pop") echo "class='selected'"; ?>><a href="<?php echo $url; ?>?filter=pop"><?php echo elgg_echo('groups:popular'); ?></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/groupgallery.php b/mod/groups/views/default/groups/groupgallery.php
new file mode 100644
index 000000000..7122dc098
--- /dev/null
+++ b/mod/groups/views/default/groups/groupgallery.php
@@ -0,0 +1,25 @@
+<?php
+ /**
+ * Elgg groups plugin gallery view
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+ $icon = elgg_view(
+ "groups/icon", array(
+ 'entity' => $vars['entity'],
+ 'size' => 'large',
+ )
+ );
+
+ $info .= "<p><b><a href=\"" . $vars['entity']->getUrl() . "\">" . $vars['entity']->name . "</a></b></p>";
+
+ // num users, last activity, owner etc
+
+
+ echo elgg_view('search/gallery_listing',array('icon' => $icon, 'info' => $info));
+?> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/grouplisting.php b/mod/groups/views/default/groups/grouplisting.php
new file mode 100644
index 000000000..d25eaff56
--- /dev/null
+++ b/mod/groups/views/default/groups/grouplisting.php
@@ -0,0 +1,49 @@
+<?php
+ /**
+ * Elgg user display (small)
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ *
+ * @uses $vars['entity'] The user entity
+ */
+
+ $icon = elgg_view(
+ "groups/icon", array(
+ 'entity' => $vars['entity'],
+ 'size' => 'small',
+ )
+ );
+
+ //get the membership type
+ $membership = $vars['entity']->membership;
+ if($membership == 2)
+ $mem = elgg_echo("groups:open");
+ else
+ $mem = elgg_echo("groups:closed");
+
+ //for admins display the feature or unfeature option
+ if($vars['entity']->featured_group == "yes"){
+ $url = elgg_add_action_tokens_to_url($vars['url'] . "action/groups/featured?group_guid=" . $vars['entity']->guid . "&action=unfeature");
+ $wording = elgg_echo("groups:makeunfeatured");
+ }else{
+ $url = elgg_add_action_tokens_to_url($vars['url'] . "action/groups/featured?group_guid=" . $vars['entity']->guid . "&action=feature");
+ $wording = elgg_echo("groups:makefeatured");
+ }
+
+ $info .= "<div class=\"groupdetails\"><p>" . $mem . " / <b>" . get_group_members($vars['entity']->guid, 10, 0, 0, true) ."</b> " . elgg_echo("groups:member") . "</p>";
+ //if admin, show make featured option
+ if(isadminloggedin())
+ $info .= "<p><a href=\"{$url}\">{$wording}</a></p>";
+ $info .= "</div>";
+ $info .= "<p><b><a href=\"" . $vars['entity']->getUrl() . "\">" . $vars['entity']->name . "</a></b></p>";
+ $info .= "<p class=\"owner_timestamp\">" . $vars['entity']->briefdescription . "</p>";
+
+ // num users, last activity, owner etc
+
+ echo elgg_view_listing($icon, $info);
+
+?>
diff --git a/mod/groups/views/default/groups/groupprofile.php b/mod/groups/views/default/groups/groupprofile.php
new file mode 100644
index 000000000..1c989c9a8
--- /dev/null
+++ b/mod/groups/views/default/groups/groupprofile.php
@@ -0,0 +1,102 @@
+<?php
+ /**
+ * Elgg groups plugin full profile view.
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+ if ($vars['full'] == true) {
+ $iconsize = "large";
+ } else {
+ $iconsize = "medium";
+ }
+
+?>
+
+<div id="groups_info_column_right"><!-- start of groups_info_column_right -->
+ <div id="groups_icon_wrapper"><!-- start of groups_icon_wrapper -->
+
+ <?php
+ echo elgg_view(
+ "groups/icon", array(
+ 'entity' => $vars['entity'],
+ //'align' => "left",
+ 'size' => $iconsize,
+ )
+ );
+ ?>
+
+ </div><!-- end of groups_icon_wrapper -->
+ <div id="group_stats"><!-- start of group_stats -->
+ <?php
+
+ echo "<p><b>" . elgg_echo("groups:owner") . ": </b><a href=\"" . get_user($vars['entity']->owner_guid)->getURL() . "\">" . get_user($vars['entity']->owner_guid)->name . "</a></p>";
+
+ ?>
+ <p><?php echo elgg_echo('groups:members') . ": " . get_entities_from_relationship('member', $vars['entity']->guid, true, 'user', '', 0, '', 9999, 0, true); ?></p>
+ </div><!-- end of group_stats -->
+</div><!-- end of groups_info_column_right -->
+
+<div id="groups_info_column_left"><!-- start of groups_info_column_left -->
+ <?php
+ if ($vars['full'] == true) {
+ if (is_array($vars['config']->group) && sizeof($vars['config']->group) > 0){
+
+ foreach($vars['config']->group as $shortname => $valtype) {
+ if ($shortname != "name") {
+ $value = $vars['entity']->$shortname;
+
+ if (!empty($value)) {
+ //This function controls the alternating class
+ $even_odd = ( 'odd' != $even_odd ) ? 'odd' : 'even';
+ }
+
+ echo "<p class=\"{$even_odd}\">";
+ echo "<b>";
+ echo elgg_echo("groups:{$shortname}");
+ echo ": </b>";
+
+ $options = array(
+ 'value' => $vars['entity']->$shortname
+ );
+
+ if ($valtype == 'tags') {
+ $options['tag_names'] = $shortname;
+ }
+
+ echo elgg_view("output/{$valtype}", $options);
+
+ echo "</p>";
+ }
+ }
+ }
+ }
+ ?>
+</div><!-- end of groups_info_column_left -->
+
+<div id="groups_info_wide">
+
+ <p class="groups_info_edit_buttons">
+
+<?php
+ if ($vars['entity']->canEdit())
+ {
+
+?>
+
+ <a href="<?php echo $vars['url']; ?>mod/groups/edit.php?group_guid=<?php echo $vars['entity']->getGUID(); ?>"><?php echo elgg_echo("edit"); ?></a>
+
+
+<?php
+
+ }
+
+?>
+
+ </p>
+</div>
+<div class="clearfloat"></div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/icon.php b/mod/groups/views/default/groups/icon.php
new file mode 100644
index 000000000..7390200d9
--- /dev/null
+++ b/mod/groups/views/default/groups/icon.php
@@ -0,0 +1,48 @@
+<?php
+
+ /**
+ * Elgg group icon
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ *
+ * @uses $vars['entity'] The user entity. If none specified, the current user is assumed.
+ * @uses $vars['size'] The size - small, medium or large. If none specified, medium is assumed.
+ */
+
+ $group = $vars['entity'];
+
+ if ($group instanceof ElggGroup) {
+
+ // Get size
+ if (!in_array($vars['size'],array('small','medium','large','tiny','master','topbar')))
+ $vars['size'] = "medium";
+
+ // Get any align and js
+ if (!empty($vars['align'])) {
+ $align = " align=\"{$vars['align']}\" ";
+ } else {
+ $align = "";
+ }
+
+ if ($icontime = $vars['entity']->icontime) {
+ $icontime = "{$icontime}";
+ } else {
+ $icontime = "default";
+ }
+
+
+?>
+
+<div class="groupicon">
+<a href="<?php echo $vars['entity']->getURL(); ?>" class="icon" ><img src="<?php echo $vars['entity']->getIcon($vars['size']); ?>" border="0" <?php echo $align; ?> title="<?php echo $name; ?>" <?php echo $vars['js']; ?> /></a>
+</div>
+
+<?php
+
+ }
+
+?> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/invitationrequests.php b/mod/groups/views/default/groups/invitationrequests.php
new file mode 100644
index 000000000..fbbbafb22
--- /dev/null
+++ b/mod/groups/views/default/groups/invitationrequests.php
@@ -0,0 +1,44 @@
+<div class="contentWrapper">
+
+<?php
+
+ if (!empty($vars['invitations']) && is_array($vars['invitations'])) {
+ $user = get_loggedin_user();
+ foreach($vars['invitations'] as $group)
+ if ($group instanceof ElggGroup) {
+
+?>
+ <div class="reportedcontent_content active_report">
+ <div class="groups_membershiprequest_buttons">
+ <?php
+ echo "<div class=\"member_icon\"><a href=\"" . $group->getURL() . "\">";
+ echo elgg_view("profile/icon", array(
+ 'entity' => $group,
+ 'size' => 'small',
+ 'override' => 'true'
+ ));
+ echo "</a></div>{$group->name}<br />";
+
+ echo str_replace('<a', '<a class="delete_report_button" ', elgg_view('output/confirmlink',array(
+ 'href' => $vars['url'] . "action/groups/killinvitation?user_guid={$user->getGUID()}&group_guid={$group->getGUID()}",
+ 'confirm' => elgg_echo('groups:joinrequest:remove:check'),
+ 'text' => elgg_echo('delete'),
+ )));
+ $url = elgg_add_action_tokens_to_url("{$vars['url']}action/groups/join?user_guid={$user->guid}&group_guid={$group->guid}");
+ ?>
+ <a href="<?php echo $url; ?>" class="archive_report_button"><?php echo elgg_echo('accept'); ?></a>
+ <br /><br />
+ </div>
+ </div>
+<?php
+
+ }
+
+ } else {
+
+ echo "<p>" . elgg_echo('groups:invitations:none') . "</p>";
+
+ }
+
+?>
+</div>
diff --git a/mod/groups/views/default/groups/members.php b/mod/groups/views/default/groups/members.php
new file mode 100644
index 000000000..66f2604c0
--- /dev/null
+++ b/mod/groups/views/default/groups/members.php
@@ -0,0 +1,30 @@
+<?php
+ /**
+ * Elgg groups items view.
+ * This is the messageboard, members, pages and latest forums posts. Each plugin will extend the views
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+ //var_export($vars['entity']);
+?>
+
+<div id="group_members">
+<h2><?php echo elgg_echo("groups:members"); ?></h2>
+
+<?php
+
+ $members = $vars['entity']->getMembers(10);
+ foreach($members as $mem){
+
+ echo "<div class=\"member_icon\"><a href=\"".$mem->getURL()."\">" . elgg_view("profile/icon",array('entity' => $mem, 'size' => 'tiny', 'override' => 'true')) . "</a></div>";
+
+ }
+
+?>
+<div class="clearfloat" /></div>
+</div> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/membershiprequests.php b/mod/groups/views/default/groups/membershiprequests.php
new file mode 100644
index 000000000..9ac37990a
--- /dev/null
+++ b/mod/groups/views/default/groups/membershiprequests.php
@@ -0,0 +1,44 @@
+<div class="contentWrapper">
+
+<?php
+
+ if (!empty($vars['requests']) && is_array($vars['requests'])) {
+
+ foreach($vars['requests'] as $request)
+ if ($request instanceof ElggUser) {
+
+?>
+ <div class="reportedcontent_content active_report">
+ <div class="groups_membershiprequest_buttons">
+ <?php
+ echo "<div class=\"member_icon\"><a href=\"" . $request->getURL() . "\">";
+ echo elgg_view("profile/icon", array(
+ 'entity' => $request,
+ 'size' => 'small',
+ 'override' => 'true'
+ ));
+ echo "</a></div>{$request->name}<br />";
+
+ echo str_replace('<a', '<a class="delete_report_button" ', elgg_view('output/confirmlink',array(
+ 'href' => $vars['url'] . 'action/groups/killrequest?user_guid='.$request->guid.'&group_guid=' . $vars['entity']->guid,
+ 'confirm' => elgg_echo('groups:joinrequest:remove:check'),
+ 'text' => elgg_echo('delete'),
+ )));
+ $url = elgg_add_action_tokens_to_url("{$vars['url']}action/groups/addtogroup?user_guid={$request->guid}&group_guid={$vars['entity']->guid}");
+ ?>
+ <a href="<?php echo $url; ?>" class="archive_report_button"><?php echo elgg_echo('accept'); ?></a>
+ <br /><br />
+ </div>
+ </div>
+<?php
+
+ }
+
+ } else {
+
+ echo "<p>" . elgg_echo('groups:requests:none') . "</p>";
+
+ }
+
+?>
+</div>
diff --git a/mod/groups/views/default/groups/profileitems.php b/mod/groups/views/default/groups/profileitems.php
new file mode 100644
index 000000000..7309c8a71
--- /dev/null
+++ b/mod/groups/views/default/groups/profileitems.php
@@ -0,0 +1,28 @@
+<?php
+ /**
+ * Elgg groups items view.
+ * This is the messageboard, members, pages and latest forums posts. Each plugin will extend the views
+ *
+ * @package ElggGroups
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider
+ * @copyright Curverider Ltd 2008-2010
+ * @link http://elgg.com/
+ */
+
+ //forum
+ echo "<div class=\"clearfloat\"></div><div id=\"fullcolumn\">";
+ echo elgg_view("groups/forum_latest",array('entity' => $vars['entity']));
+ echo "</div>";
+
+ //right column
+ echo "<div id=\"right_column\">";
+ echo elgg_view("groups/right_column",array('entity' => $vars['entity']));
+ echo "</div>";
+
+ //left column
+ echo "<div id=\"left_column\">";
+ echo elgg_view("groups/left_column",array('entity' => $vars['entity']));
+ echo "</div>";
+
+?> \ No newline at end of file
diff --git a/mod/groups/views/default/groups/side_menu.php b/mod/groups/views/default/groups/side_menu.php
new file mode 100644
index 000000000..7de921ed0
--- /dev/null
+++ b/mod/groups/views/default/groups/side_menu.php
@@ -0,0 +1,10 @@
+<div class="sidebarBox">
+<div id="owner_block_submenu"><ul>
+<?php
+ if(isloggedin()){
+ echo "<li><a href=\"{$vars['url']}pg/groups/member/{$_SESSION['user']->username}\">". elgg_echo('groups:yours') ."</a></li>";
+ echo "<li><a href=\"{$vars['url']}pg/groups/invitations/{$_SESSION['user']->username}\">". elgg_echo('groups:invitations') ."</a></li>";
+ echo "<li><a href=\"{$vars['url']}pg/groups/new/\">". elgg_echo('groups:new') ."</a></li>";
+ }
+?>
+</ul></div></div> \ No newline at end of file