Introduction
Introduction Statistics Contact Development Disclaimer Help
Fix bug where incorrect elements in the navigation sidebar were highlighted, th…
git clone git://git.suckless.org/swerc
Log
Files
Refs
README
---
commit 8cc1b6cf53766e23aea89970973b728ef54588a2
parent 64316c376d802bf5918b977dd2bf936b1f0451d0
Author: [email protected] <unknown>
Date: Thu, 6 Aug 2009 02:20:58 +0200
Fix bug where incorrect elements in the navigation sidebar were highlighted, th…
Diffstat:
M bin/corehandlers.rc | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/bin/corehandlers.rc b/bin/corehandlers.rc
@@ -26,7 +26,11 @@ fn nav_tree {
path = $0 d
gsub(/[\-_]/, " ", bname)
- if(index(ENVIRON["req_path"] "/", path) == 1)
+ # To avoid false matches add trailing / even for plain files to act as…
+ pa = path
+ gsub(/[^\/]$/, "&/", pa)
+
+ if(index(ENVIRON["req_path"] "/", pa) == 1)
print "<li><a href=\"" path "\" class=\"thisPage\">&raquo;<i> " bn…
else
print "<li><a href=\"" path "\">&rsaquo; " bname "</a></li>"
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.