jami1955
Member
Posted 1 year ago #
I need to limit the number of child pages listed, the call creating the list is:
<?php wp_list_pages('child_of=868&sort_column=post_title&title_li=') ?>
I tried this:
<?php wp_list_pages('child_of=868&number=3&sort_column=post_title&title_li=') ?>
but the entire list disappeared, so can anyone tell me how to write the parameter limiting the list to a certain number?
thanks
JSC
jami1955
Member
Posted 1 year ago #
@esmi
The link you've given I've read. In particular the part about limiting the number of pages, or specifying the number of pages does not work. There is a note there on that page saying it does not work. Here's the note as it appears there:
number
(integer) Sets the number of Pages to display. This causes the SQL LIMIT value to be defined. Default to no LIMIT. (This parameter was added with Version 2.8) NOTE: this is currently not working, see http://core.trac.wordpress.org/ticket/10745
So, I'm wondering if anyone found a way to get it to work. Doesn't look like it....
thanks,
JSC
I think your only other option is to build your own page list using get_pages.