aboutsummaryrefslogtreecommitdiff
path: root/mod/notifications/start.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-03 03:33:52 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-03 03:33:52 +0000
commit949a233076ec18f86e60f90a7a8837cb422664af (patch)
tree0286c9cb2c3301a164505e39dccf02a4e0a98497 /mod/notifications/start.php
parentd4e4268d11612408e4989a5c57f69fcb2febe8aa (diff)
downloadelgg-949a233076ec18f86e60f90a7a8837cb422664af.tar.gz
elgg-949a233076ec18f86e60f90a7a8837cb422664af.tar.bz2
Refs #2428 almost done removing CONFIG access - mostly plugin start.php left
git-svn-id: http://code.elgg.org/elgg/trunk@7999 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/notifications/start.php')
-rw-r--r--mod/notifications/start.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/mod/notifications/start.php b/mod/notifications/start.php
index 624207e89..6f489f94d 100644
--- a/mod/notifications/start.php
+++ b/mod/notifications/start.php
@@ -8,7 +8,6 @@
function notifications_plugin_init() {
- global $CONFIG;
elgg_extend_view('css/screen','notifications/css');
@@ -28,8 +27,9 @@ function notifications_plugin_init() {
elgg_register_event_handler('create', 'friend', 'notifications_update_friend_notify');
elgg_register_plugin_hook_handler('access:collections:add-user', 'collection', 'notifications_update_collection_notify');
- elgg_register_action("notificationsettings/save", $CONFIG->pluginspath . "notifications/actions/save.php");
- elgg_register_action("notificationsettings/groupsave", $CONFIG->pluginspath . "notifications/actions/groupsave.php");
+ $actions_base = elgg_get_plugin_path() . 'notifications/actions';
+ elgg_register_action("notificationsettings/save", "$actions_base/save.php");
+ elgg_register_action("notificationsettings/groupsave", "$actions_base/groupsave.php");
}
/**
@@ -38,20 +38,21 @@ function notifications_plugin_init() {
* @param array $page Array of url parameters
*/
function notifications_page_handler($page) {
- global $CONFIG;
// default to personal notifications
if (!isset($page[0])) {
$page[0] = 'personal';
}
+ $base = elgg_get_plugin_path() . 'notifications';
+
switch ($page[0]) {
case 'group':
- require $CONFIG->pluginspath . "notifications/groups.php";
+ require "$base/groups.php";
break;
case 'personal':
default:
- require $CONFIG->pluginspath . "notifications/index.php";
+ require "$base/index.php";
break;
}