Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

correctly display links in the root namespace. closes #5

  • Loading branch information...
commit 0e11c54da64fcaff9020daa35b637dcd8f7c9193 1 parent 3ffeaba
Andreas Gohr authored October 20, 2010
2  plugin.info.txt
... ...
@@ -1,7 +1,7 @@
1 1
 base   navi
2 2
 author Andreas Gohr
3 3
 email  gohr@cosmocode.de
4  
-date   2009-03-09
  4
+date   2010-10-20
5 5
 name   Navigation Plugin
6 6
 desc   Build a navigation menu from a list
7 7
 url    http://www.dokuwiki.org/plugin:navi
9  syntax.php
@@ -74,12 +74,11 @@ function handle($match, $state, $pos, &$handler){
74 74
             }elseif($instructions[$i][0] == 'listitem_close'){
75 75
                 $cnt++;
76 76
             }elseif($instructions[$i][0] == 'internallink'){
77  
-                $page = cleanID($instructions[$i][1][0]);
78 77
                 $list[$page] = array(
79 78
                                      'parents' => $parents,
80  
-                                     'page' => cleanID($instructions[$i][1][0]),
81  
-                                     'title' => $instructions[$i][1][1],
82  
-                                     'lvl' => $lvl
  79
+                                     'page'    => cleanID($instructions[$i][1][0]),
  80
+                                     'title'   => $instructions[$i][1][1],
  81
+                                     'lvl'     => $lvl
83 82
                                     );
84 83
             }
85 84
         }
@@ -177,7 +176,7 @@ function render($format, &$R, $data) {
177 176
 
178 177
             $R->listcontent_open();
179 178
             if(($format == 'xhtml') && ($info['page'] == $current)) $R->doc .= '<span class="current">';
180  
-            $R->internallink($info['page'],$info['title']);
  179
+            $R->internallink(':'.$info['page'],$info['title']);
181 180
             if(($format == 'xhtml') && ($info['page'] == $current)) $R->doc .= '</span>';
182 181
             $R->listcontent_close();
183 182
         }

0 notes on commit 0e11c54

Please sign in to comment.
Something went wrong with that request. Please try again.