post_edit_category_parent_dropdown_args

過濾鉤子
apply_filters( 'post_edit_category_parent_dropdown_args', $parent_dropdown_args )
引數
  • (array) $parent_dropdown_args { Optional. Array of arguments to generate parent dropdown. @type string $taxonomy Name of the taxonomy to retrieve. @type bool $hide_if_empty True to skip generating markup if no categories are found. Default 0. @type string $name Value for the 'name' attribute of the select element. Default "new{$tax_name}_parent". @type string $orderby Which column to use for ordering terms. Default 'name'. @type bool|int $hierarchical Whether to traverse the taxonomy hierarchy. Default 1. @type string $show_option_none Text to display for the "none" option. Default "— {$parent} —", where `$parent` is 'parent_item' taxonomy label. }
    Required:
定義位置
相關勾子
taxonomy_parent_dropdown_argswidget_categories_dropdown_argsdisable_categories_dropdownwidget_archives_dropdown_argspost_edit_form_tag
相關方法
get_category_parentswalk_category_dropdown_treeparent_dropdownwp_edit_attachments_query_varswalk_page_dropdown_treeget_category_by_path
引入
4.4.0
棄用
-

post_row_actions。這個鉤子允許你在WordPress儀表盤的”文章”螢幕上的行操作(如”編輯”或”垃圾桶”)列表中新增自定義操作。使用這個鉤子,你可以新增自定義連結,在點選時執行特定的動作。

在“編輯後”頁面上過濾分類父下拉選單的引數。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
$parent_dropdown_args = apply_filters( 'post_edit_category_parent_dropdown_args', $parent_dropdown_args );
$parent_dropdown_args = apply_filters( 'post_edit_category_parent_dropdown_args', $parent_dropdown_args );
$parent_dropdown_args = apply_filters( 'post_edit_category_parent_dropdown_args', $parent_dropdown_args );

常見問題

FAQs
檢視更多 >