diff --git a/wp-includes/post-template.php b/wp-includes/post-template.php
index 522ad3e..0438761 100644
|
a
|
b
|
function wp_list_pages($args = '') { |
| 879 | 879 | * <ul> |
| 880 | 880 | * <li><strong>sort_column</strong> - How to sort the list of pages. Defaults |
| 881 | 881 | * to 'menu_order, post_title'. Use column for posts table.</li> |
| | 882 | * <li><strong>menu_element</strong> - If you set this argument, it will |
| | 883 | * replace the element containing the menu with the specified HTML element.</li> |
| 882 | 884 | * <li><strong>menu_class</strong> - Class to use for the div ID which contains |
| 883 | 885 | * the page list. Defaults to 'menu'.</li> |
| 884 | 886 | * <li><strong>echo</strong> - Whether to echo list or return it. Defaults to |
| … |
… |
function wp_list_pages($args = '') { |
| 896 | 898 | * @return string html menu |
| 897 | 899 | */ |
| 898 | 900 | function wp_page_menu( $args = array() ) { |
| 899 | | $defaults = array('sort_column' => 'menu_order, post_title', 'menu_class' => 'menu', 'echo' => true, 'link_before' => '', 'link_after' => ''); |
| | 901 | $defaults = array( |
| | 902 | 'sort_column' => 'menu_order, post_title', |
| | 903 | 'menu_element' => 'div', |
| | 904 | 'menu_class' => 'menu', |
| | 905 | 'echo' => true, |
| | 906 | 'link_before' => '', |
| | 907 | 'link_after' => '' |
| | 908 | ); |
| | 909 | |
| 900 | 910 | $args = wp_parse_args( $args, $defaults ); |
| 901 | 911 | $args = apply_filters( 'wp_page_menu_args', $args ); |
| 902 | 912 | |
| … |
… |
function wp_page_menu( $args = array() ) { |
| 932 | 942 | if ( $menu ) |
| 933 | 943 | $menu = '<ul>' . $menu . '</ul>'; |
| 934 | 944 | |
| 935 | | $menu = '<div class="' . esc_attr($args['menu_class']) . '">' . $menu . "</div>\n"; |
| | 945 | $menu = '<' . $args['menu_element'] . ' class="' . esc_attr($args['menu_class']) . '">' . $menu . '</' . $args['menu_element'] . ">\n"; |
| 936 | 946 | $menu = apply_filters( 'wp_page_menu', $menu, $args ); |
| 937 | 947 | if ( $args['echo'] ) |
| 938 | 948 | echo $menu; |