walk_category_dropdown_tree

函数


walk_category_dropdown_tree ( $args )
参数
  • (mixed)
    $args
    Elements array, maximum hierarchical depth and optional additional arguments.
    Required:
返回值
  • (string)
相关
  • Walker::walk()
定义位置
  • wp-includes/category-template.php
    , line 1136
引入
2.1.0
弃用

Retrieves HTML dropdown (select) content for category list.

function walk_category_dropdown_tree( ...$args ) {
	// The user's options are the third parameter.
	if ( empty( $args[2]['walker'] ) || ! ( $args[2]['walker'] instanceof Walker ) ) {
		$walker = new Walker_CategoryDropdown;
	} else {
		/**
		 * @var Walker $walker
		 */
		$walker = $args[2]['walker'];
	}
	return $walker->walk( ...$args );
}
声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。