WP_Media_List_Table::column_comments

Advertisement

Summery Summery

Handles the comments column output.

Syntax Syntax

WP_Media_List_Table::column_comments( WP_Post $post )

Parameters Parameters

$post

(Required) The current WP_Post object.

Source Source

File: wp-admin/includes/class-wp-media-list-table.php

			<?php
			if ( $user_can_edit ) {
				$title = _draft_or_post_title( $post->post_parent );
				printf(
					'<br /><a href="#the-list" onclick="findPosts.open( \'media[]\', \'%s\' ); return false;" class="hide-if-no-js aria-button-if-js" aria-label="%s">%s</a>',
					$post->ID,
					/* translators: %s: Attachment title. */
					esc_attr( sprintf( __( 'Attach &#8220;%s&#8221; to existing content' ), $title ) ),
					__( 'Attach' )
				);
			}
		}
	}

Advertisement

Changelog Changelog

Changelog
Version Description
4.3.0 Introduced.

Advertisement

Leave a Reply