aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/elgglib.php
diff options
context:
space:
mode:
Diffstat (limited to 'engine/lib/elgglib.php')
-rw-r--r--engine/lib/elgglib.php17
1 files changed, 15 insertions, 2 deletions
diff --git a/engine/lib/elgglib.php b/engine/lib/elgglib.php
index 856852729..5cd0a1995 100644
--- a/engine/lib/elgglib.php
+++ b/engine/lib/elgglib.php
@@ -1013,8 +1013,9 @@ function set_template_handler($function_name) {
* @param string $view The view to add to.
* @param string $view_name The name of the view to extend
* @param int $priority The priority, from 0 to 1000, to add at (lowest numbers will be displayed first)
+ * @param string $viewtype Not used
*/
-function extend_view($view, $view_name, $priority = 501, $viewtype = '') {
+function elgg_extend_view($view, $view_name, $priority = 501, $viewtype = '') {
global $CONFIG;
if (!isset($CONFIG->views)) {
@@ -1038,6 +1039,18 @@ function extend_view($view, $view_name, $priority = 501, $viewtype = '') {
}
/**
+ * @deprecated 1.7. Use elgg_extend_view().
+ * @param $view
+ * @param $view_name
+ * @param $priority
+ * @param $viewtype
+ */
+function extend_view($view, $view_name, $priority = 501, $viewtype = '') {
+ elgg_log('extend_view() was deprecated in 1.7 by elgg_extend_view()!', 'WARNING');
+ elgg_extend_view($view, $view_name, $priority, $viewtype);
+}
+
+/**
* Set an alternative base location for a view (as opposed to the default of $CONFIG->viewpath)
*
* @param string $view The name of the view
@@ -2372,7 +2385,7 @@ function __elgg_shutdown_hook() {
function elgg_init() {
// Page handler for JS
register_page_handler('js','js_page_handler');
- extend_view('js/initialise_elgg','embed/js');
+ elgg_extend_view('js/initialise_elgg','embed/js');
// Register an event triggered at system shutdown
register_shutdown_function('__elgg_shutdown_hook');