Some of you may be interested in the following page: http://www.longrange.org/nav_test/page_1.php
It utilizes some php code mentioned on this list which is designed to automatically adjust the styling of the active link. It is a quite elegant solution to achieving highlighting for an active link, especially, in my case, where I am using Dreamweaver templates that have a complex scheme for making specific html tags editable. I adapted it a bit so that it works with a horizontal menu. The "easynav.php" script came from here: http://onlinetools.org/tools/easynav/ and creates a vertical menu with submenus. I've adapted the script a bit, including commenting out an "exit;" that was killing my page early. I don't understand the php adequately enough to full get what is going on, but i was able to make some adaptations to it to meet my needs and get it to work the way I wanted it to. I got some help with the horizontal list styling from one of the horizontal menu sites mentioned on this listserv, but now I can't figure out which one it was to give the author credit. Here are the elements of the page: easynav.php --The code that drives it. nav.css --My butchered revisions of the CSS stylesheet. nav.html --The html file that acts as a template page_1.php, page_2.php . . . --The linked pages. It is quite elegant, as once you get the CSS layout right, all you have to do is insert: <?php include('easynav.php');?> where you want a menu list and the script builds the list of links and automatically highlights the link to active page as you want it highlighted. The only adjustment necessary is inserting the appropriate links in the template and setting the styles to your liking in the stylesheet. One nice feature is the fact that any links you add or changes you make to the nav.html template or stylesheet will automatically show up on all of your pages utilizing the php script. Insert the script in an uneditable region in a Dreamweaver template and it will update the navigation for all the pages built on that template as well as styling the active page throughout your site as you want it to be styled. Excuse the butchered CSS code. I did a lot of adjusting and haven't cleaned it up. Would be interested in any modifications or other applications people make from it. I'm wondering if, by using two template files and two script files, one could get it to highlight the link to the active secondary page in a standard left side vertical menu column while keeping the active link in the horizontal menu highlighted as well. This is really a php design issue. It does, however, show the powerful results that can be achieved through integrating CSS and php. Most of the work I did was getting the css right. --Kenoli Kenoli Oleari Neighborhood Assemblies Network [EMAIL PROTECTED] 510-601-8217 http://www.horizonsofchange.com http://www.sfnan.org ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
