aboutsummaryrefslogtreecommitdiff
path: root/mod/groups
diff options
context:
space:
mode:
Diffstat (limited to 'mod/groups')
-rw-r--r--mod/groups/actions/addtogroup.php2
-rw-r--r--mod/groups/actions/join.php2
-rw-r--r--mod/groups/all.php2
-rw-r--r--mod/groups/index.php2
-rw-r--r--mod/groups/membership.php2
-rw-r--r--mod/groups/start.php18
-rw-r--r--mod/groups/views/default/forum/maintopic.php2
-rw-r--r--mod/groups/views/default/groups/invitationrequests.php2
-rw-r--r--mod/groups/views/default/groups/membershiprequests.php2
-rw-r--r--mod/groups/views/default/object/groupforumtopic.php4
10 files changed, 16 insertions, 22 deletions
diff --git a/mod/groups/actions/addtogroup.php b/mod/groups/actions/addtogroup.php
index 6f63ff446..dab44666d 100644
--- a/mod/groups/actions/addtogroup.php
+++ b/mod/groups/actions/addtogroup.php
@@ -69,7 +69,7 @@
add_entity_relationship($group->guid, 'invited', $user->guid);
// Send email
- $url = "{$CONFIG->url}pg/groups/invited?user_guid={$user->guid}&group_guid={$group->guid}";
+ $url = elgg_get_site_url()."pg/groups/invited?user_guid={$user->guid}&group_guid={$group->guid}";
if (notify_user($user->getGUID(), $group->owner_guid,
sprintf(elgg_echo('groups:invite:subject'), $user->name, $group->name),
sprintf(elgg_echo('groups:invite:body'), $user->name, $logged_in_user->name, $group->name, $url),
diff --git a/mod/groups/actions/join.php b/mod/groups/actions/join.php
index 158da372c..40f227ba7 100644
--- a/mod/groups/actions/join.php
+++ b/mod/groups/actions/join.php
@@ -51,7 +51,7 @@
{
// Closed group, request membership
system_message(elgg_echo('groups:privategroup'));
- forward(elgg_add_action_tokens_to_url($CONFIG->url . "action/groups/joinrequest?user_guid=$user_guid&group_guid=$group_guid", FALSE));
+ forward(elgg_add_action_tokens_to_url("action/groups/joinrequest?user_guid=$user_guid&group_guid=$group_guid", FALSE));
exit;
}
}
diff --git a/mod/groups/all.php b/mod/groups/all.php
index c51097910..354437c7e 100644
--- a/mod/groups/all.php
+++ b/mod/groups/all.php
@@ -56,7 +56,7 @@
$title = sprintf(elgg_echo("groups:all"), elgg_get_page_owner()->name);
if(isloggedin()){
- $area1 .= elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'groups', 'new_link' => "{$CONFIG->url}pg/groups/new"));
+ $area1 .= elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'groups', 'new_link' => "pg/groups/new"));
}
$area1 .= elgg_view("groups/group_sort_menu", array("count" => $group_count, "filter" => $filter)) . $objects;
$body = elgg_view_layout('one_column_with_sidebar', $area1, $area2);
diff --git a/mod/groups/index.php b/mod/groups/index.php
index 398996072..48ff99805 100644
--- a/mod/groups/index.php
+++ b/mod/groups/index.php
@@ -13,7 +13,7 @@
$title = elgg_echo("groups:owned");
// Get objects
- $area1 = elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'groups', 'new_link' => "{$CONFIG->url}pg/groups/new"));
+ $area1 = elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'groups', 'new_link' => "pg/groups/new"));
set_context('search');
$objects = elgg_list_entities(array('types' => 'group', 'owner_guid' => elgg_get_page_owner_guid(), 'limit' => $limit, 'offset' => $offset, 'full_view' => FALSE));
diff --git a/mod/groups/membership.php b/mod/groups/membership.php
index b479018ca..ace899772 100644
--- a/mod/groups/membership.php
+++ b/mod/groups/membership.php
@@ -19,7 +19,7 @@
} else $title = elgg_echo("groups:owned");
// Get objects
- $area2 = elgg_view('page_elements/content_header', array('context' => "mine", 'type' => 'groups', 'new_link' => "{$CONFIG->url}pg/groups/new"));
+ $area2 = elgg_view('page_elements/content_header', array('context' => "mine", 'type' => 'groups', 'new_link' => "pg/groups/new"));
set_context('search');
// offset is grabbed in the list_entities_from_relationship() function
diff --git a/mod/groups/start.php b/mod/groups/start.php
index 1d00782c4..f24a3106a 100644
--- a/mod/groups/start.php
+++ b/mod/groups/start.php
@@ -335,19 +335,13 @@
* @return string File URL
*/
function groups_url($entity) {
-
- global $CONFIG;
-
$title = elgg_get_friendly_title($entity->name);
- return $CONFIG->url . "pg/groups/{$entity->guid}/$title/";
+ return "pg/groups/{$entity->guid}/$title/";
}
function groups_groupforumtopic_url($entity) {
-
- global $CONFIG;
- return $CONFIG->url . 'mod/groups/topicposts.php?topic='. $entity->guid .'&group_guid=' . $entity->container_guid;
-
+ return 'mod/groups/topicposts.php?topic='. $entity->guid .'&group_guid=' . $entity->container_guid;
}
/**
@@ -502,7 +496,7 @@
$filehandler->setFilename("groups/" . $entity->guid . $size . ".jpg");
if ($filehandler->exists()) {
- $url = $CONFIG->url . "pg/groupicon/{$entity->guid}/$size/$icontime.jpg";
+ $url = elgg_get_site_url() . "pg/groupicon/{$entity->guid}/$size/$icontime.jpg";
return $url;
}
@@ -536,7 +530,7 @@
function group_topicpost_url($annotation) {
if ($parent = get_entity($annotation->entity_guid)) {
global $CONFIG;
- return elgg_get_site_url() . 'mod/groups/topicposts.php?topic='.$parent->guid.'&group_guid='.$parent->container_guid.'#' . $annotation->id;
+ return 'mod/groups/topicposts.php?topic='.$parent->guid.'&group_guid='.$parent->container_guid.'#' . $annotation->id;
}
}
@@ -581,7 +575,7 @@
if ($params['owner'] instanceof ElggGroup && $group_owner->forum_enable != 'no') {
$return_value[] = array(
'text' => elgg_echo('groups:forum'),
- 'href' => "{$CONFIG->url}pg/groups/forum/{$params['owner']->getGUID()}"
+ 'href' => "pg/groups/forum/{$params['owner']->getGUID()}"
);
}
return $return_value;
@@ -593,7 +587,7 @@
if ($params['owner'] instanceof ElggGroup) {
$return_value[] = array(
'text' => elgg_echo('Activity'),
- 'href' => "{$CONFIG->url}pg/groups/activity/{$params['owner']->getGUID()}"
+ 'href' => "pg/groups/activity/{$params['owner']->getGUID()}"
);
}
return $return_value;
diff --git a/mod/groups/views/default/forum/maintopic.php b/mod/groups/views/default/forum/maintopic.php
index 9a3cc64cb..61b6c49fd 100644
--- a/mod/groups/views/default/forum/maintopic.php
+++ b/mod/groups/views/default/forum/maintopic.php
@@ -26,7 +26,7 @@
if (groups_can_edit_discussion($vars['entity'], elgg_get_page_owner()->owner_guid)) {
echo "<div class='entity_metadata'>";
echo "<span class='delete_button'>".elgg_view("output/confirmlink",array(
- 'href' => elgg_get_site_url() . "action/groups/deletepost?post=" . $vars['entity']->id . "&topic=" . get_input('topic') . "&group=" . get_input('group_guid'),
+ 'href' => "action/groups/deletepost?post=" . $vars['entity']->id . "&topic=" . get_input('topic') . "&group=" . get_input('group_guid'),
'text' => elgg_echo('delete'),
'confirm' => elgg_echo('deleteconfirm')
))."</span>";
diff --git a/mod/groups/views/default/groups/invitationrequests.php b/mod/groups/views/default/groups/invitationrequests.php
index 297dc31d4..c905cf8f7 100644
--- a/mod/groups/views/default/groups/invitationrequests.php
+++ b/mod/groups/views/default/groups/invitationrequests.php
@@ -21,7 +21,7 @@ if (!empty($vars['invitations']) && is_array($vars['invitations'])) {
<a href="<?php echo $url; ?>" class="submit_button"><?php echo elgg_echo('accept'); ?></a>
<?php
echo str_replace('<a', '<a class="action_button disabled" ', elgg_view('output/confirmlink',array(
- 'href' => elgg_get_site_url() . "action/groups/killinvitation?user_guid={$user->getGUID()}&group_guid={$group->getGUID()}",
+ 'href' => "action/groups/killinvitation?user_guid={$user->getGUID()}&group_guid={$group->getGUID()}",
'confirm' => elgg_echo('groups:invite:remove:check'),
'text' => elgg_echo('delete'),
)));
diff --git a/mod/groups/views/default/groups/membershiprequests.php b/mod/groups/views/default/groups/membershiprequests.php
index 6dde33bd4..dbd65a667 100644
--- a/mod/groups/views/default/groups/membershiprequests.php
+++ b/mod/groups/views/default/groups/membershiprequests.php
@@ -22,7 +22,7 @@
<a href="<?php echo $url; ?>" class="submit_button"><?php echo elgg_echo('accept'); ?></a>
<?php
echo str_replace('<a', '<a class="action_button disabled" ', elgg_view('output/confirmlink',array(
- 'href' => elgg_get_site_url() . 'action/groups/killrequest?user_guid='.$request->guid.'&group_guid=' . $vars['entity']->guid,
+ 'href' => 'action/groups/killrequest?user_guid='.$request->guid.'&group_guid=' . $vars['entity']->guid,
'confirm' => elgg_echo('groups:joinrequest:remove:check'),
'text' => elgg_echo('delete'),
)));
diff --git a/mod/groups/views/default/object/groupforumtopic.php b/mod/groups/views/default/object/groupforumtopic.php
index 9729c9d83..2d5b1e094 100644
--- a/mod/groups/views/default/object/groupforumtopic.php
+++ b/mod/groups/views/default/object/groupforumtopic.php
@@ -53,14 +53,14 @@ if (get_context() == "search") {
// display the delete link to those allowed to delete
$info .= "<div class='entity_metadata'>";
$info .= '<span class="entity_edit">' . elgg_view("output/url", array(
- 'href' => elgg_get_site_url() . "mod/groups/edittopic.php?group={$vars['entity']->container_guid}&topic={$vars['entity']->guid}",
+ 'href' => "mod/groups/edittopic.php?group={$vars['entity']->container_guid}&topic={$vars['entity']->guid}",
'text' => elgg_echo('edit'),
));
$info .= '</span>';
// display the delete link to those allowed to delete
$info .= '<span class="delete_button">' . elgg_view("output/confirmlink", array(
- 'href' => elgg_get_site_url() . "action/groups/deletetopic?topic=" . $vars['entity']->guid . "&group=" . $vars['entity']->container_guid,
+ 'href' => "action/groups/deletetopic?topic=" . $vars['entity']->guid . "&group=" . $vars['entity']->container_guid,
'text' => elgg_echo('delete'),
'confirm' => elgg_echo('deleteconfirm'),
));