<?php add_contextual_help$screen$help ); ?> 

add_contextual_help() 用法



(string) (必填) The handle for the screen to add help to. This is usually the hook name returned by the add_*_page() functions.

默认值: None


(string) (必填) An arbitrary string containing HTML for help text.

默认值: None

add_contextual_help() 参数


When using this function to add contextual help to an admin page created by a plugin or theme, it is important to remember that the add_*_page() set of functions build and return custom hook names - which are needed in order to use add_contextual_help().

This page hook name is usually made up of two page slugs separated by an underscore - the slug for the current page (as defined in your add_*_page() function), an underscore, and the slug for the parent page.

For example, if you created a new "theme_options" subpage under the Admin > Appearance menu (which itself has a slug of "appearance_page"), your page hook would be "appearance_page_theme_options".

To modify or add to the hard-coded help text for default WordPress admin pages, you have to use the gettext 过滤器 hook.

add_contextual_help() 注意


add_contextual_help() 历史


add_contextual_help() 函数的代码位于 wp-admin/includes/template.php.

add_contextual_help() 源文件