WordPress.org

Support

Support » How-To and Troubleshooting » [Resolved] Displaying Child Pages – 1 is randomly omitted?

[Resolved] Displaying Child Pages – 1 is randomly omitted?

  • I did this: http://codex.wordpress.org/Function_Reference/get_pages#Displaying_Child_pages_of_the_current_page_in_post_format

    I didn’t modify that snippet at all, it’s an exact C/P.

    It’s always worked for me before (I have multiple sites), but for some reason on this particular one, it’s omitting a child page? I can’t find any rhyme or reason to it. It’s the first child page I created out of 3. The other 2 display fine. Furthermore, the child page is displayed properly in the dropdown menu.

    It didn’t work when I had no page order associated, and it also doesn’t work when I do. It’s a little weird.

    My hierarchy goes like:

    Classes
    -For Kids (Page to display children on)
    -Mommy and Me (doesn’t work)
    -Art classes (works)
    -Drawing classes (works)

    Again, it works fine in my dropdown hierarchy (default Twenty-ten theme), so I’m at a loss.

    Any ideas? Thanks a bunch in advance. It’s making me like this: >:(

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hm, the formatting messed up my hierarchy.

    Classes
    –For Kids (Page to display children on)
    —–Mommy and Me (doesn’t work)
    —–Art classes (works)
    —–Drawing classes (works)

    Nevermind. It was this part of the code:

    if($count >= 2)
    			break;

    It only shows the 2 most recent. I just deleted this conditional, and it works a-okay.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Displaying Child Pages – 1 is randomly omitted?’ is closed to new replies.