diff options
-rw-r--r-- | engine/lib/pagehandler.php | 15 | ||||
-rw-r--r-- | htaccess_dist | 4 |
2 files changed, 7 insertions, 12 deletions
diff --git a/engine/lib/pagehandler.php b/engine/lib/pagehandler.php index cc347ed17..b993469d8 100644 --- a/engine/lib/pagehandler.php +++ b/engine/lib/pagehandler.php @@ -26,20 +26,15 @@ $query = parse_url($_SERVER['REQUEST_URI']);
if (isset($query['query'])) {
- $query = $query['query'];
- $query = rawurldecode($query);
- $query = explode('&',$query);
- if (sizeof($query) > 0) {
- foreach($query as $queryelement) {
- $vals = explode('=',$queryelement, 2);
- if (sizeof($vals) > 1) {
- set_input(urldecode($vals[0]),urldecode($vals[1]));
- }
+ parse_str($query['query'], $query_arr);
+ if (is_array($query_arr)) {
+ foreach($query_arr as $name => $val) {
+ set_input($name, $val);
}
}
}
-
$page = explode('/',$page);
+
if (!isset($CONFIG->pagehandler) || empty($handler)) {
$result = false;
} else if (isset($CONFIG->pagehandler[$handler]) && is_callable($CONFIG->pagehandler[$handler])) {
diff --git a/htaccess_dist b/htaccess_dist index eb9b3afcc..00c29ab79 100644 --- a/htaccess_dist +++ b/htaccess_dist @@ -130,6 +130,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/(.+)/?$ engine/handlers/pagehandler.php?handler=search&page=$1
+RewriteRule ^tag/(.+)/?$ engine/handlers/pagehandler.php?handler=search&page=$1 [B]
-</IfModule>
\ No newline at end of file +</IfModule>
|