Alert: This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.

WP_Posts_List_Table::_display_rows() WordPress Method

The WP_Posts_List_Table::_display_rows() method is used to display the rows for a posts list table. This method is called by the WP_Posts_List_Table::display() method.

WP_Posts_List_Table::_display_rows( array $posts, int $level ) #


Parameters

$posts

(array)(Required)

$level

(int)(Required)


Top ↑

Source

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

	private function _display_rows( $posts, $level = 0 ) {
		$post_type = $this->screen->post_type;

		// Create array of post IDs.
		$post_ids = array();

		foreach ( $posts as $a_post ) {
			$post_ids[] = $a_post->ID;
		}

		if ( post_type_supports( $post_type, 'comments' ) ) {
			$this->comment_pending_count = get_pending_comments_num( $post_ids );
		}

		foreach ( $posts as $post ) {
			$this->single_row( $post, $level );
		}
	}

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.