WordPress.org

Support

Support » Themes and Templates » How to Get Child Pages Listed Under Parent

How to Get Child Pages Listed Under Parent

  • Some themes I’ve tried will display in a menu only the parent pages. When you hover the mouse cursor over one of the pages, a list of the child pages drops down.

    Unfortunately, the themes that I like for other reasons lack this feature. How can I add it?

    Lane

Viewing 4 replies - 1 through 4 (of 4 total)
  • It is just a matter of dragging them below the parent pages. I suggest read this document which has pictures to guide you.

    What is your theme called. Sometimes you might need a plugin but first try without any plugins.

    Good luck.

    Thanks. There seems to be no link associated with “this document.”

    I found how to drag the child pages to the parent in the Menu setup. However, in the displayed menu the children are listed below the parent and indented. If possible, I would like them not to show up until the mouse cursor is hovered over the parent entry.

    I’m currently using the simplecorp theme at http://readingforbrightminds.com/

    The menu is question is in a sidebar widget.

    Lane

    Assuming that you only have one-level child, this might work. Add this to your CSS:

    .sub-menu {
    position: absolute;
    left: -9999px; // hides the menu
    }
    
    #menu-main li:hover .sub-menu {
    position: relative;
    left: 0; //show the menu when it's hovered
    }

    It’s only a very rough try though.

    For more you might be interested in taking a look at this 🙂 http://csswizardry.com/2011/02/creating-a-pure-css-dropdown-menu/

    Thank you very much. The code you provided did exactly what I wanted.

    Lane

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to Get Child Pages Listed Under Parent’ is closed to new replies.
Skip to toolbar