WordPress Editing Admin Help Tab

Edit: just add a screenshot of the part I want to change for clarity: screenshot for clarity

I am trying to create and change the Backpack WordPress help tabs in the upper right corner of the screen with my own content, ive tried to use the code, but I'm not sure if I am looking at the correct link, does it work or not, implementing it correctly, but nothing changes when I try to use it even in the default use state. This is an im link using: [codex reference] [2]

Edit 2: found this article on how to edit text, but it doesn’t seem to work, it just puts the output text and then breaks it, this code is outdated or something is missing to me, below is a screenshot of what happens and the code used from the site. using an index, because it seems like the one used for the control panel, but changing it has the same effect. screenshot of how code output

add_action('load-index-new.php','custom_help_page');
add_action('load-index.php','custom_help_page');
function custom_help_page() {
  add_filter('contextual_help','custom_page_help');
}
function custom_page_help($help) {
  // echo $help; // Uncomment if you just want to append your custom Help text to the default Help text
  echo "<h5>Custom Help text</h5>";
  echo "<p> HTML goes here.</p>";
}

------ deleted the old code because it was incorrect for this purpose, the new one above. ------

+4
source share
1 answer

This can help:

How to add submenu to WordPress admin panel

Control Panel Menu Settings

But to add a link, you can:

add_action( 'admin_bar_menu', 'toolbar_link_to_mypage', 999 );

function toolbar_link_to_mypage( $wp_admin_bar ) {
    $args = array(
        'id'    => 'my_page',
        'title' => 'My Page',
        'href'  => 'http://example.com/my-page/',
        'meta'  => array( 'class' => 'my-toolbar-page' )
    );
    $wp_admin_bar->add_node( $args );
}

Strike>


EDIT:

, :

""

+1

Source: https://habr.com/ru/post/1611296/


All Articles