WordPress.org

Ready to get started?Download WordPress

Forums

Leaf
[resolved] Make pages invisible in top nav menu (5 posts)

  1. gabrielavio
    Member
    Posted 1 year ago #

    Hi,

    I want to make certain pages invisible in the navigation menu.

    I read about the wp_list_pages function and the exclude paramenter, but I just can't find the function in the php files for the leaf theme.

    Where can I use this:

      <?php wp_list_pages('exclude=17,38' ); ?>

    Or what else do I need to do?

    Thanks!

  2. Andrew
    Forum Moderator
    Posted 1 year ago #

    Could you instead make a new menu in Appearance > Menus (dashboard) and then only add in the menu items you want?

  3. gabrielavio
    Member
    Posted 1 year ago #

    I'm not sure what you mean, because I never added these pages to the Appearance > Menus.
    I just did Pages > Add new - and they were automatically showing in the nav menu.
    These pages don't show up in the Appearance > Menus though.

    Any other suggestions?

  4. tizz
    Member
    Posted 1 year ago #

    Make a new menu in Appearance > Menus (dashboard) and then only add in the menu items you want

    It's the better suggestion

  5. gabrielavio
    Member
    Posted 1 year ago #

    Hi guys,
    Thanks for your help! I was a little stubborn, but I tried it out and you were absolutely right :)

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.