• here is the code:

    <div id="navbar">
         <ul id="nav">
            <?php wp_list_pages('sort_column=menu_order&depth=1&title_li=&exclude=2,4,25,27');?>
         </ul>
       </div><!-- end menu -->

    Two questions:

    How do i exclude the home page with this code? The home page is set to the static page.

    Also, here is my permalink structure /%category%/%postname%/.html
    in order to exlcude, i had to go back and change the permalinks to default (page numbers) then add the numbers into the exclude, and then change back to my custom one.

    Is there a way to put the custom permalink ie about-us into the exclude?

    thanks

Viewing 12 replies - 1 through 12 (of 12 total)
  • <?php wp_list_pages('sort_column=menu_order&depth=1&title_li=&exclude=2,4,25,27, N');?>

    where N = the id of your Home page. See identifying page ids.

    Thread Starter xmatter

    (@xmatter)

    thank you, but the home has no ID but “home”. does this relate to the fact that the home page is also the static page? when i hover according to the link you sent, it displays “Edit “home””.

    Thread Starter xmatter

    (@xmatter)

    thank you, but the home has no ID but “home”. does this relate to the fact that the home page is also the static page? when i hover according to the link you sent, it displays “Edit “home””.

    If you;re using a static home page, you’ll have a Page listed in Admin -> Pages. You need to find the id of that Page using the method outlined in the link I gave above.

    Thread Starter xmatter

    (@xmatter)

    the home page is static through admin > settings > reading settings.
    There is no page ID through the admin > pages on hover, only “edit home”. and through the address bar, no page id either. when i go to admin > pages and edit the home page, it simply ends with .com/

    Any other thoughts?

    don’t forget, my permalink structure is /%category%/%postname%/.html

    the home page is static through admin > settings > reading settings.

    What is the name of the Page you have chosen in the dropdown?

    Thread Starter xmatter

    (@xmatter)

    the front page: home
    the posts page: blank (chose nothing)

    Then find the page called Home in Admin -> Pages.

    Thread Starter xmatter

    (@xmatter)

    thank you for all your help, but i wish i could send you a screenshot to show that there is no page ID or number or anything regarding the home page. I know how to exclude pages, but the home page threw me off since it had no ID, hence posting on the forums

    Thread Starter xmatter

    (@xmatter)

    when i change the static page to another page, the link then becomes .com/home

    So you must have a page called Home!

    Site url?

    Thread Starter xmatter

    (@xmatter)

    ok so here’s what i had to do. I had to change the static page to something then change my permalink structure to “Default” then go get the page number. finally go it. now i must change everything back. esmi, thank you, and if you get time, please setup a local server with my setting posted above, and you will see that it wasn’t easy to discover how to get that page ID

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘exlcude home page & permalink structure’ is closed to new replies.