Support » Fixing WordPress » need to show child links on child page

  • Resolved renzoroberts


    Here is what I am trying to do.

    I would like to list the child pages of FUN without list all the parent pages.
    I tried
    < ?php wp_list_pages(‘depth=3’ . ‘child_of=159’); ? >
    but that shows all of the parents and other child pages.

    I tried
    < ?php wp_list_pages(‘child_of=159’ . ‘depth=2’); ? >
    but then nothing is displayed.

    I’m looking for an easy way to display one level of ‘fun stuff’ links without having to use a bunch of excludes to eliminate the second level.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Assuming that the page id for Fun Emails is 159, then using just
    < ?php wp_list_pages('child_of=159');
    should only list pages Adams First, Are You Normal, Dear Bubba etc.

    Just FYI if you are using multiple parameters use the & sign:
    < ?php wp_list_pages('depth=3&child_of=159'); ? >

    Thanks for the help.
    I did not know that I need the ‘&’ between multiple parameters.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘need to show child links on child page’ is closed to new replies.