<?php $defaults = array(
'theme_location' => ,
'menu' => ,
'container' => 'p',
'container_class' => 'menu-{menu slug}-container',
'container_id' => ,
'menu_class' => 'menu',
'menu_id' => ,
'echo' => true,
'fallback_cb' => 'wp_page_menu',
'before' => ,
'after' => ,
'link_before' => ,
'link_after' => ,
'depth' => 0,
'walker' => );
?>
假如是多菜单的话,如下调用
<?php echo wp_nav_menu( array( 'container_class' => 'menu-header', 'theme_location' => 'primary' ) ) ?>
依据能否登录生成不同该菜单栏
<?php
1 |
'before' => ,<BR> 'after' => ,<BR> 'link_before' => ,<BR> 'link_after' => ,<BR> |
以上就是安达网络工作室关于《wordpress之wp_nav_menu使用说明》的一些看法。更多内容请查看本栏目更多内容!
1、在仪表盘增加子菜单: add_submenu_page( 'index.php', … ); 2、在文章处增加子菜单: add_submenu...
首先,在主题functions.php中添加上面的代码: 复制代码代码如下:function wp_dashboard_GongGao() { if...
前言 前几天,冤家手头上有一个闲暇的vps,256M内存,我决议拿来玩一下。通过一番考虑,还是用来挂站吧。而...
之前有网友提出,在WordPress中有没有方法完成每篇文章只容许用户评论一次? 暂不说这个需要有没有用,毕竟...
其实我集体并不是很喜爱这种摘要的显示形式,然而这个办法用起来比拟不便而已。 WordPress是有摘要性能...
本文实例讲述了WordPress完成评论后可显示内容中附件下载地址的办法。分享给大家供大家参考,详细如下: 最...