Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2007-12-14 15:29:30
- parlour
- Member
- From: Germany
- Registered: 2006-09-01
- Posts: 20
Apply a CSS-class to the active link in a dynamic menu
For the Website I’m making at the moment I’m using a menu, hard coded into a form. The active link (the place where the user is at the moment) gets the CSS-class selected with the plugin thm_if_article (works with article ids).
I have one tiny part of the menu that’s dynamic, i.e. new elements will be added, old ones deleted. It is of course perfectly simple to do that with article_custom:
<txp:article_custom form="dynamic_menu" category="Sonderausstellungen" />
And dynamic_menu is then:
<li><txp:permlink><txp:title /></txp:permlink></li>
That adds all articles in the category “Sonderausstellungen” to the menu.
I, however, couldn’t figure out how to add the CSS-class selected to the active (and only the active) link in this dynamic menu. Is that even possible?
Last edited by parlour (2007-12-14 15:32:49)
Offline
Re: Apply a CSS-class to the active link in a dynamic menu
would glx_hl_current help?
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
#3 2007-12-14 16:08:05
- parlour
- Member
- From: Germany
- Registered: 2006-09-01
- Posts: 20
Re: Apply a CSS-class to the active link in a dynamic menu
Wow, great! Works really perfectly. Thanks!
Offline