aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engine/lib/entities.php14
-rw-r--r--htaccess_dist2
2 files changed, 15 insertions, 1 deletions
diff --git a/engine/lib/entities.php b/engine/lib/entities.php
index 93f12b057..6f0bad1e6 100644
--- a/engine/lib/entities.php
+++ b/engine/lib/entities.php
@@ -2335,6 +2335,19 @@
}
}
+/**
+ * Page handler for search
+ *
+ * @param array $page Page elements from pain page handler
+ */
+ function search_page_handler($page) {
+ if (isset($page[0])) {
+ global $CONFIG;
+ set_input('tag',$page[0]);
+ include_once($CONFIG->path . "search/index.php");
+ }
+ }
+
/**
* Returns a viewable list of entities based on the registered types
*
@@ -2723,6 +2736,7 @@
*/
function entities_init() {
register_page_handler('view','entities_page_handler');
+ register_page_handler('search','search_page_handler');
// Allow a permission override for recursive entity deletion
// TODO: Can this be done better?
diff --git a/htaccess_dist b/htaccess_dist
index 4237460a0..9e6c40beb 100644
--- a/htaccess_dist
+++ b/htaccess_dist
@@ -124,6 +124,6 @@ RewriteRule ^pg\/([A-Za-z0-9\_\-]+)$ engine/handlers/pagehandler.php?handler=$1
RewriteRule xml-rpc.php engine/handlers/xml-rpc_handler.php
RewriteRule mt/mt-xmlrpc.cgi engine/handlers/xml-rpc_handler.php
-RewriteRule ^tag/(.+)/?$ search/?tag=$1
+RewriteRule ^tag/(.+)/?$ engine/handlers/pagehandler.php?handler=search&page=$1
</IfModule> \ No newline at end of file