nav_menu_item_args
apply_filters( ‘nav_menu_item_args’, stdClass $args , WP_Post $item , int $depth )
过滤钩子:过滤单个导航菜单项的参数。
Filter Hook: Filters the arguments for a single nav menu item.
参数(Parameters)
参数 | 类型 | 说明 |
---|---|---|
$args | (stdClass) | wp_nav_menu()参数的对象。 |
$item | (WP_Post) | 菜单项数据对象。 |
$depth | (int) | 菜单项的深度。用于填充。 |
源码(Source)
更新版本 | 源码位置 | 使用 | 被使用 |
---|---|---|---|
4.4.0 | wp-includes/class-walker-nav-menu.php:140 | 1 | 0 |
nav_menu_item_args 为WP2原创文章,链接:https://www.wp2.cn/hook/nav_menu_item_args/