WordPress.org

Support

Support » How-To and Troubleshooting » How? Pages in page order excluding sub-pages?

How? Pages in page order excluding sub-pages?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Andrew Ozz
    WordPress Dev

    @azaozz

    “depth (integer)
    This parameter controls how many levels in the hierarchy of pages are to be included in the list generated by wp_list_pages. The default value is 0 (display all pages, including all sub-pages); depth=-1 shows no sub-pages; depth=1 only shows the top level of Pages; a value greater than 1 includes the sub-pages up to the corresponding level in the pages hierarchy.”

    So wp_list_pages('depth=-1');?

    charlene2021
    Member

    @charlene2021

    works, thanks very much!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How? Pages in page order excluding sub-pages?’ is closed to new replies.