Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

MDL-27171 messages: meet require_once usage gudelines

Signed-off-by: Ruslan Kabalin <ruslan.kabalin@luns.net.uk>
  • Loading branch information...
commit 60bbe7684ab6ec83c5670f2aa64d7be665757fa8 1 parent a4de1d8
Ruslan Kabalin authored
View
4 admin/message.php
@@ -21,8 +21,8 @@
* @copyright 2011 Lancaster University Network Services Limited
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
-require_once(dirname(dirname(__FILE__)) . '/config.php');
-require_once(dirname(dirname(__FILE__)) . '/message/lib.php');
+require_once(dirname(__FILE__) . '/../config.php');
+require_once($CFG->dirroot . '/message/lib.php');
require_once($CFG->libdir.'/adminlib.php');
// This is an admin page
View
4 message/defaultoutputs.php
@@ -21,8 +21,8 @@
* @copyright 2011 Lancaster University Network Services Limited
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
-require_once(dirname(dirname(__FILE__)) . '/config.php');
-require_once(dirname(dirname(__FILE__)) . '/message/lib.php');
+require_once(dirname(__FILE__) . '/../config.php');
+require_once($CFG->dirroot . '/message/lib.php');
require_once($CFG->libdir.'/adminlib.php');
// This is an admin page
View
4 message/edit.php
@@ -23,8 +23,8 @@
* @package message
*/
-require_once(dirname(dirname(__FILE__)) . '/config.php');
-require_once(dirname(dirname(__FILE__)) . '/message/lib.php');
+require_once(dirname(__FILE__) . '/../config.php');
+require_once($CFG->dirroot . '/message/lib.php');
$userid = optional_param('id', $USER->id, PARAM_INT); // user id
$course = optional_param('course', SITEID, PARAM_INT); // course id (defaults to Site)
Please sign in to comment.
Something went wrong with that request. Please try again.