mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 09:37:42 +01:00
Check post_type_supports before adding comments column to attachments. Translate a string. props johnbillion, SergeyBiryukov. fixes #18644.
git-svn-id: http://svn.automattic.com/wordpress/trunk@18931 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
0a1fe6dc02
commit
4dfdd9ea97
@ -137,7 +137,8 @@ class WP_Media_List_Table extends WP_List_Table {
|
||||
/* translators: column name */
|
||||
if ( !$this->detached ) {
|
||||
$posts_columns['parent'] = _x( 'Attached to', 'column name' );
|
||||
$posts_columns['comments'] = '<span class="vers"><img alt="Comments" src="' . esc_url( admin_url( 'images/comment-grey-bubble.png' ) ) . '" /></span>';
|
||||
if ( post_type_supports( 'attachment', 'comments' ) )
|
||||
$posts_columns['comments'] = '<span class="vers"><img alt="' . esc_attr__( 'Comments' ) . '" src="' . esc_url( admin_url( 'images/comment-grey-bubble.png' ) ) . '" /></span>';
|
||||
}
|
||||
/* translators: column name */
|
||||
$posts_columns['date'] = _x( 'Date', 'column name' );
|
||||
|
Loading…
Reference in New Issue
Block a user