Stumped on sub-page lister (2 posts)

  1. aluminumcans
    Posted 10 years ago #

    I'm using the sample on this page:


    which is here:

    <?php if(wp_list_pages("child_of=\".$post->ID.\"&echo=0\")) { ?>

      <?php wp_list_pages("title_li=&child_of=\".$post->ID.\"&sort_column=menu_order&show_date=modified&date_format=$date_format\");?>

    <?php } ?>

    to list the child pages. I have the above code in a page_sidebar.php file that I am including in my page.php template.

    Alas, nothing happens. No error...the page_sidebar.php is just never loaded. If I remove the PHP tag above from that file, then it is included.

    Not sure what to check to figure out the issue. Is the code snippet above dependant on some other code I'm not including?

  2. aluminumcans
    Posted 10 years ago #

    Maybe a better followup question:

    How do I get WP to show errors? As it is now, if it can't execute the include page, it just doesn't do it. It'd be great if I could actually get an error message to point me in the right direction.

Topic Closed

This topic has been closed to new replies.

About this Topic