View Full Version : AJAX Accordian Menus - Can a button show that it was the one that was "Selected"?

05-05-2008, 09:49 PM
I'm building a site with the accordian navigation found here (http://www.dynamicdrive.com/dynamicindex17/ddaccordionmenu.htm) and I'm just wondering if there is a way to make a CSS Class that will change the color of the button that was selected when a person clicks in the nav?

For example, say a person clicks the button "Home" and they are taken to the homepage of a site. Is there a way to define a class in the CSS script that will change the color of the Home button in the navigation to show that the person is on the Home page?

I have a site that will have quite a few pages so I'm looking to show which page a user is on by changing its color in the navigation when clicked.

Thanks in advance for any help that anyone can provide.

05-05-2008, 10:48 PM
It's not so much a question of defining a CSS class, but rather, how to tell the script which page it's currently on (and hence select the corresponding link). A similar question was asked here: http://www.dynamicdrive.com/forums/showthread.php?t=32058

05-06-2008, 01:27 AM
Thanks, I think that would be a great feature in the future, but I'm definitely satisfied with the script as-is considering how smooth and awesome it is. Keep up the great work, and thanks for the reply!