Hello,
I searched for solutions for this but all the ones i found are for more complicated setups like these:
-----------------------------------------------------------------------------------
http://www.couchcms.com/forum/viewtopic.php?f=4&t=8496&p=15995&hilit=current+page+navigation#p15995
http://www.couchcms.com/forum/viewtopic.php?f=4&t=6934&p=8820&hilit=current+page+nav#p8820
------------------------------------------------------------------------------------
PROBLEM:
I just need to find a way to identify when a main directory is being viewed
And or
one of it's sub-directories is being viewed so i can style the link in the navigation accordingly.
MY SETUP:
I can easily do an "if" condition to add the html id to one of the main current directory links. But what i don't know how to do is how to detect (a sub directory) to highlight its "Parent Directory link" in the navigation.
I have a simple website with 4 MAIN directories, the links are in an HTML snippet and embedded in the site's header. The website has many sub-directories and when a user is in any of them only it's parent link has to be "styled" with an html id. (all the html pages are named index.html, so identifying the directory with the name i believe is out of the question)
Is there maybe a way to see if the current page's link a user is on contains part of the main directories link (url)?
I searched for solutions for this but all the ones i found are for more complicated setups like these:
-----------------------------------------------------------------------------------
http://www.couchcms.com/forum/viewtopic.php?f=4&t=8496&p=15995&hilit=current+page+navigation#p15995
http://www.couchcms.com/forum/viewtopic.php?f=4&t=6934&p=8820&hilit=current+page+nav#p8820
------------------------------------------------------------------------------------
PROBLEM:
I just need to find a way to identify when a main directory is being viewed
And or
one of it's sub-directories is being viewed so i can style the link in the navigation accordingly.
MY SETUP:
I can easily do an "if" condition to add the html id to one of the main current directory links. But what i don't know how to do is how to detect (a sub directory) to highlight its "Parent Directory link" in the navigation.
I have a simple website with 4 MAIN directories, the links are in an HTML snippet and embedded in the site's header. The website has many sub-directories and when a user is in any of them only it's parent link has to be "styled" with an html id. (all the html pages are named index.html, so identifying the directory with the name i believe is out of the question)
Is there maybe a way to see if the current page's link a user is on contains part of the main directories link (url)?