Remove Static page in Menu – WordPress

WordPress now has a cool option that allows you to make one of the pages a static front page so that your site’s main look is always the same. However; in your menu, that page will show up when really, it shouldn’t! If it does, you end up with two links to your main page and wasted real estate for your menu.

The solution, find (usually in the header) the
$tmpexclude = get_option(‘page_on_front’);
$tmpline = ‘sort_column=menu_order& depth=1&title_li=&exclude =’ . $tmpexclude;
wp_list_pages($tmpline);

That should eliminate the duplicate

Comments

  1. rmharrington says:

    Hi.

    Don’t make the issue complicated.

    On the right side of your page creation page, youj will see a button that makes pages public or privite. Just make the duplicate menu page private.

    Mike
    rmharrington
    Grace is a way of walking in the shadow of Jesus.

Speak Your Mind

Comment moderation is enabled. Your comment may take some time to appear.