我有一個沃克班申請我的子菜單,但我如何獲得子子項目到這個代碼?下面sub-submenu walker method
是我的代碼
的functions.php
<?php
class wp_submenu_class extends Walker_nav_menu {
function start_lvl(&$output, $depth) {
$indent = str_repeat("\t", $depth);
$output .= "\n$indent<ul class=\"submenu\">\n";
}
}
?>
的header.php
<div class="navi">
<?php wp_nav_menu(array(
'menuitems' => 'mymenu',
'container' => '',
'container_id' => '',
'menu_class' => 'topmenu',
'menu_id' => '',
'items_wrap' => '<ul id="" class="%2$s">%3$s</ul>',
'walker' => new wp_submenu_class()));
?>
</div>
按照此: - [Docs1](http://codex.wordpress.org/Function_Reference/wp_nav_menu#Using_a_Custom_Walker_Function)** ** OR [文檔2 ](http://codex.wordpress.org/Class_Reference/Walker) –
thanx akshay ...但我是一個新手,並飛過了我的頭...你可以幫我的代碼? – user3117694