[Pmwiki-users] Sidebar Highlighting?

Hochstrasser Benedikt bhoc
Sun Sep 26 13:25:52 CDT 2004


Hi all,

Is there a halfway simple way to highlight the corresponding sidebar
entry when a page is open? 
Let's say I have a sidebar navigator that points to page1, page2 and
page3 respectively. When I am on page1 (from deep linking or from
wherever) I'd like that the "page1" entry in the sidebar is highlighted
(some css attribute). 
I know I could write a different sidebar for every page, but that's not
extremely elegant.

Oh, and one more thing:
I noticed that PHP5 treats path_info a tad different (depending on the
server) than PHP4. (The variable in question is
$_SERVER["ORIG_PATH_INFO"]). If you modify pmwiki.php, line ~223

if ($pagename=='' && $EnablePathInfo)
  $pagename = @substr($_SERVER['PATH_INFO'],1);

to

if ($pagename=='' && $EnablePathInfo)
  $pagename = @substr($_SERVER['PATH_INFO'],1);
if ($pagename=='' && $EnablePathInfo)
  $pagename = @substr($_SERVER['ORIG_PATH_INFO'],1);

then you should be fine with either PHP version.

-- 
Ben



More information about the pmwiki-users mailing list