WordPress.org

Plugin Directory

List Pages Shortcode

Introduces the [list-pages], [sibling-pages] and [child-pages] shortcodes for easily displaying a list of pages within a post or page.

How do I include a page excerpt?

Firstly you will need to add support for excerpt for your pages. You can either you this by using the add_post_type_support() function or using a plugin like Page Excerpt.

You can also use the 'list_pages_shortcode_excerpt' filter to return or customize the excerpt for specific pages. The following example:

<?php
function my_list_pages_shortcode_excerpt( $excerpt, $page, $depth, $args ) {
    return $excerpt . '...';
}
add_filter( 'list_pages_shortcode_excerpt', 'my_list_pages_shortcode_excerpt', 10, 4 );
?>

You can then include the excerpt via your shortcode.

[list-pages excerpt="1"]

Requires: 3.5 or higher
Compatible up to: 4.2.3
Last Updated: 2015-4-23
Active Installs: 10,000+

Ratings

4.8 out of 5 stars

Support

0 of 1 support threads in the last two months have been resolved.

Got something to say? Need help?

Compatibility

+
=
Not enough data

1 person says it works.
0 people say it's broken.

100,1,1
100,1,1
100,2,2
100,3,3
100,3,3
100,1,1
100,1,1
100,1,1 100,1,1
100,2,2
100,2,2 100,3,3 100,1,1
100,1,1
100,1,1
0,1,0 100,2,2
100,1,1
100,7,7
100,2,2
100,6,6
100,4,4
100,1,1
100,2,2 100,6,6 100,1,1
100,2,2 100,3,3
100,2,2
100,3,3 100,1,1
100,2,2 100,1,1
50,2,1 100,1,1
100,3,3
100,1,1
100,2,2 100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,2,2
100,1,1
100,1,1