summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--inc/parser/xhtml.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/inc/parser/xhtml.php b/inc/parser/xhtml.php
index a132d4f4b..63f79d17c 100644
--- a/inc/parser/xhtml.php
+++ b/inc/parser/xhtml.php
@@ -839,15 +839,18 @@ class Doku_Renderer_xhtml extends Doku_Renderer {
*/
function _simpleTitle($name){
global $conf;
+
if($conf['useslash']){
$nssep = '[:;/]';
}else{
$nssep = '[:;]';
}
- return preg_replace('!.*'.$nssep.'!','',$name);
+ $name = preg_replace('!.*'.$nssep.'!','',$name);
+ //if there is a hash we use the ancor name only
+ $name = preg_replace('!.*#!','',$name);
+ return $name;
}
-
/**
* Renders internal and external media
*