Make WordPress Core

Ticket #25837: 25837.6.diff

File 25837.6.diff, 2.1 KB (added by obenland, 10 years ago)

Limits Help tab to only "post" post type edit screen

  • wp-content/themes/twentyfourteen/inc/customizer.php

     
    331331 * @return void
    332332 */
    333333function twentyfourteen_contextual_help() {
     334        if ( 'admin_head-edit.php' == current_filter() && 'post' != $GLOBALS['typenow'] ) {
     335                return;
     336        }
     337
    334338        get_current_screen()->add_help_tab( array(
    335339                'id'      => 'twentyfourteen',
    336340                'title'   => __( 'Twenty Fourteen', 'twentyfourteen' ),
    337341                'content' =>
    338342                        '<ul>' .
    339                                 '<li>' . sprintf( __( 'The home page features your choice of up to 6 posts prominently displayed in a grid or slider, controlled by the <a href="%1$s">"featured" tag</a>; you can change the tag and layout in <a href="%2$s">Appearance &rarr; Customize</a>. If no posts match the tag, <a href="%3$s">"sticky" posts</a> will be displayed instead.', 'twentyfourteen' ), admin_url( '/edit.php?tag=featured' ), admin_url( 'customize.php' ), admin_url( '/edit.php?show_sticky=1' ) ). '</li>' .
     343                                '<li>' . sprintf( __( 'The home page features your choice of up to 6 posts prominently displayed in a grid or slider, controlled by the <a href="%1$s">"featured" tag</a>; you can change the tag and layout in <a href="%2$s">Appearance &rarr; Customize</a>. If no posts match the tag, <a href="%3$s">"sticky" posts</a> will be displayed instead.', 'twentyfourteen' ), admin_url( '/edit.php?tag=featured' ), admin_url( 'customize.php' ), admin_url( '/edit.php?show_sticky=1' ) ) . '</li>' .
    340344                                '<li>' . sprintf( __( 'Enhance your site design by using <a href="%s">Featured Images</a> for posts you&rsquo;d like to stand out (also known as post thumbnails). This allows you to associate an image with your post without inserting it. Twenty Fourteen uses featured images for posts and pages&mdash;above the title&mdash;and in the Featured Content area on the home page.', 'twentyfourteen' ), 'http://codex.wordpress.org/Post_Thumbnails#Setting_a_Post_Thumbnail' ) . '</li>' .
    341345                        '</ul>',
    342346        ) );