Link post title on comments for a single post screen. Fixes #15609

git-svn-id: https://develop.svn.wordpress.org/trunk@16619 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
scribu 2010-11-29 21:23:20 +00:00
parent 0829265944
commit 9f5043b6dc

View File

@ -126,7 +126,17 @@ require_once('./admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo esc_html( $title );
<h2><?php
if ( $post_id )
echo sprintf(__('Comments on &#8220;%s&#8221;'),
sprintf('<a href="%s">%s</a>',
get_edit_post_link($post_id),
wp_html_excerpt(_draft_or_post_title($post_id), 50)
)
);
else
echo __('Comments');
if ( isset($_REQUEST['s']) && $_REQUEST['s'] )
printf( '<span class="subtitle">' . sprintf( __( 'Search results for &#8220;%s&#8221;' ), wp_html_excerpt( esc_html( stripslashes( $_REQUEST['s'] ) ), 50 ) ) . '</span>' ); ?>
</h2>