Ticket #10968: 10968.diff
File 10968.diff, 1.5 KB (added by , 10 years ago) |
---|
-
src/wp-includes/post-template.php
1195 1195 * @type string $sort_column How to short the list of pages. Accepts post column names. 1196 1196 * Default 'menu_order, post_title'. 1197 1197 * @type string $menu_class Class to use for the div ID containing the page list. Default 'menu'. 1198 * @type string $menu_tag Element to use for the element containing the page list. Default 'div'. 1198 1199 * @type bool $echo Whether to echo the list or return it. Accepts true (echo) or false (return). 1199 1200 * Default true. 1200 1201 * @type int|bool|string $show_home Whether to display the link to the home page. Can just enter the text … … 1211 1212 $defaults = array( 1212 1213 'sort_column' => 'menu_order, post_title', 1213 1214 'menu_class' => 'menu', 1215 'menu_tag' => 'div', 1214 1216 'echo' => true, 1215 1217 'show_home' => false, 1216 1218 'link_before' => '', … … 1264 1266 if ( $menu ) { 1265 1267 $menu = $args['before'] . $menu . $args['after']; 1266 1268 } 1267 $menu = '<div class="' . esc_attr($args['menu_class']) . '">' . $menu . "</div>\n"; 1269 $tag = sanitize_text_field( $args['menu_tag'] ); 1270 $menu = "<{$args['menu_tag']} class=\"" . esc_attr( $args['menu_class'] ) . '">' . $menu . "</{$args['menu_tag']}>\n"; 1268 1271 1269 1272 /** 1270 1273 * Filter the HTML output of a page-based menu.