summaryrefslogtreecommitdiff
path: root/inc/parser
diff options
context:
space:
mode:
authorAdrian Lang <lang@cosmocode.de>2010-06-23 10:08:28 +0200
committerAdrian Lang <lang@cosmocode.de>2010-06-23 10:08:57 +0200
commit3d5e07d9f0f7f71f91cd97f4a7484f4da8a1841a (patch)
treebacd1a1fe2e14161ee374e9beff11efcc96575dc /inc/parser
parentdef4baf24186bf30d4ba5ea726fb7c8391d8b43f (diff)
downloadrpg-3d5e07d9f0f7f71f91cd97f4a7484f4da8a1841a.tar.gz
rpg-3d5e07d9f0f7f71f91cd97f4a7484f4da8a1841a.tar.bz2
Do not parse URL params in internal links, just pass them through
Diffstat (limited to 'inc/parser')
-rw-r--r--inc/parser/xhtml.php14
1 files changed, 5 insertions, 9 deletions
diff --git a/inc/parser/xhtml.php b/inc/parser/xhtml.php
index f9a33fef0..c8862eece 100644
--- a/inc/parser/xhtml.php
+++ b/inc/parser/xhtml.php
@@ -560,15 +560,11 @@ class Doku_Renderer_xhtml extends Doku_Renderer {
global $conf;
global $ID;
- $params = array();
-
- if (preg_match('/^([^?]*)\?([^?]+)$/', $id, $matches)) {
- $id = $matches[1];
- preg_match_all('/(?<=[&^])([^=]+)=([^=]*)(?:&|$)/', $matches[2],
- $matches, PREG_SET_ORDER);
- foreach($matches as &$param) {
- $params[$param[1]] = $param[2];
- }
+ $params = '';
+ $parts = explode('?', $id, 2);
+ if (count($parts) === 2) {
+ $id = $parts[0];
+ $params = $parts[1];
}
// default name is based on $id as given