Support » Fixing WordPress » PHP and DHTML menus

  • peiqinglong


    Ok, this is a WordPress, PHP, DHTML menu question.

    So here is my present code (skimmed down for easy reading):

    <li<?php if (is_home()) {echo " id\"current\""; } ?>>Home
    <li<?php if (is_page(car)) {echo " id\"current\""; } ?>>Car

    So the problem I’m having is that when a person clicks, lets say Car, it puts a border-bottom under it (which is what I want), but when a person goes to a sub page under that main link, the border-bottom disappears. Is there a way to make it so that no matter what sub page under a main page is selected, the border-bottom will always appear under the main page?

    Here is another example:

    Main Page –>

    Sub Page of the Main Page –> [url][/url]


  • The topic ‘PHP and DHTML menus’ is closed to new replies.