Pass args as array instead of query string.
git-svn-id: http://svn.automattic.com/wordpress/trunk@5876 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
eb3e9e6dc7
commit
f478ddaa36
|
@ -332,13 +332,13 @@ function wp_widget_pages( $args ) {
|
||||||
|
|
||||||
$title = empty( $options['title'] ) ? __( 'Pages' ) : $options['title'];
|
$title = empty( $options['title'] ) ? __( 'Pages' ) : $options['title'];
|
||||||
$sortby = empty( $options['sortby'] ) ? 'menu_order' : $options['sortby'];
|
$sortby = empty( $options['sortby'] ) ? 'menu_order' : $options['sortby'];
|
||||||
$exclude = empty( $options['exclude'] ) ? '' : '&exclude=' . $options['exclude'];
|
$exclude = empty( $options['exclude'] ) ? '' : $options['exclude'];
|
||||||
|
|
||||||
if ( $sortby == 'menu_order' ) {
|
if ( $sortby == 'menu_order' ) {
|
||||||
$sortby = 'menu_order, post_title';
|
$sortby = 'menu_order, post_title';
|
||||||
}
|
}
|
||||||
|
|
||||||
$out = wp_list_pages( 'title_li=&echo=0&sort_column=' . $sortby . $exclude );
|
$out = wp_list_pages( array('title_li' => '', 'echo' => 0, 'sort_column' => $sortby, 'exclude' => $exclude) );
|
||||||
|
|
||||||
if ( !empty( $out ) ) {
|
if ( !empty( $out ) ) {
|
||||||
?>
|
?>
|
||||||
|
|
Loading…
Reference in New Issue