aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-06-18 21:16:00 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-06-18 21:16:00 +0000
commit677e155a31776c63fbd5701f76302e422a0dadb9 (patch)
tree23181592af997ded7980203bf6f87078c1f7fbfe /engine
parentf2aa2c6980460261f27bf01d3e074aa9b2d4bd5d (diff)
downloadelgg-677e155a31776c63fbd5701f76302e422a0dadb9.tar.gz
elgg-677e155a31776c63fbd5701f76302e422a0dadb9.tar.bz2
Merged friends pages fixes in r6501:6503 from 1.7 to trunk.
git-svn-id: http://code.elgg.org/elgg/trunk@6515 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/pagehandler.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/engine/lib/pagehandler.php b/engine/lib/pagehandler.php
index a6143a4e6..5f60eefae 100644
--- a/engine/lib/pagehandler.php
+++ b/engine/lib/pagehandler.php
@@ -86,6 +86,24 @@ function register_page_handler($handler, $function) {
}
/**
+ * Unregister a page handler for an identifier
+ *
+ * Note: to replace a page handler, call register_page_handler()
+ *
+ * @param string $handler The page type identifier
+ * @since 1.7.2
+ */
+function unregister_page_handler($handler) {
+ global $CONFIG;
+
+ if (!isset($CONFIG->pagehandler)) {
+ return;
+ }
+
+ unset($CONFIG->pagehandler[$handler]);
+}
+
+/**
* A default page handler
* Tries to locate a suitable file to include. Only works for core pages, not plugins.
*