当前位置: 首页>>代码示例>>PHP>>正文


PHP WP_Screen::add_old_compat_help方法代码示例

本文整理汇总了PHP中WP_Screen::add_old_compat_help方法的典型用法代码示例。如果您正苦于以下问题:PHP WP_Screen::add_old_compat_help方法的具体用法?PHP WP_Screen::add_old_compat_help怎么用?PHP WP_Screen::add_old_compat_help使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WP_Screen的用法示例。


在下文中一共展示了WP_Screen::add_old_compat_help方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: add_contextual_help

/**
 * Add contextual help text for a page.
 *
 * Creates a 'Screen Info' help tab.
 *
 * @since 2.7.0
 *
 * @param string    $screen The handle for the screen to add help to.  This is usually the hook name returned by the add_*_page() functions.
 * @param string    $help   The content of a 'Screen Info' help tab.
 *
 * @todo: deprecate?
 */
function add_contextual_help($screen, $help)
{
    if (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    WP_Screen::add_old_compat_help($screen, $help);
}
开发者ID:redteam,项目名称:wordpress-,代码行数:19,代码来源:screen.php

示例2: add_contextual_help

/**
 * Add contextual help text for a page.
 *
 * Creates an 'Overview' help tab.
 *
 * @since 2.7.0
 * @deprecated 3.3.0
 * @deprecated Use get_current_screen()->add_help_tab()
 * @see WP_Screen
 *
 * @param string    $screen The handle for the screen to add help to. This is usually the hook name returned by the add_*_page() functions.
 * @param string    $help   The content of an 'Overview' help tab.
 */
function add_contextual_help($screen, $help)
{
    _deprecated_function(__FUNCTION__, '3.3', 'get_current_screen()->add_help_tab()');
    if (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    WP_Screen::add_old_compat_help($screen, $help);
}
开发者ID:valiror,项目名称:sharingdais_demo1,代码行数:21,代码来源:deprecated.php

示例3: load_manage_page

 /**
  * Function is loaded by WordPress, if WP-Table Reloaded's admin menu entry is called,
  * Load the scripts, stylesheets and language, all of this will be done before the page is shown by show_manage_page()
  */
 function load_manage_page()
 {
     // show admin footer message (only on pages of WP-Table Reloaded)
     add_filter('admin_footer_text', array(&$this->helper, 'add_admin_footer_text'));
     $this->init_language_support();
     // get and check action parameter from passed variables
     $default_action = 'list';
     $default_action = apply_filters('wp_table_reloaded_default_action', $default_action);
     $this->allowed_actions = apply_filters('wp_table_reloaded_allowed_actions', $this->allowed_actions);
     $action = !empty($_REQUEST['action']) ? $_REQUEST['action'] : $default_action;
     // check if action is in allowed actions and if method is callable, if yes, call it
     if (in_array($action, $this->allowed_actions)) {
         $this->action = $action;
     }
     add_thickbox();
     // load js and css for admin, needs to stand below thickbox script
     $this->add_manage_page_js();
     // will add script to footer
     $this->add_manage_page_css();
     // needs to be added to the header
     // done after determining the action, because needs action parameter to load correct help string
     if (version_compare($GLOBALS['wp_version'], '3.3', '>')) {
         WP_Screen::add_old_compat_help(convert_to_screen($this->hook), $this->helper->get_contextual_help_string());
     } else {
         add_contextual_help($this->hook, $this->helper->get_contextual_help_string());
     }
 }
开发者ID:vsalx,项目名称:rattieinfo,代码行数:31,代码来源:controller-admin.php


注:本文中的WP_Screen::add_old_compat_help方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。