WP_Plugin_Install_List_Table::no_items()publicWP 1.0

Method of the class: WP_Plugin_Install_List_Table{}

No Hooks.

Return

null. Nothing (null).

Usage

$WP_Plugin_Install_List_Table = new WP_Plugin_Install_List_Table();
$WP_Plugin_Install_List_Table->no_items();

WP_Plugin_Install_List_Table::no_items() code WP 6.5.2

<?php
public function no_items() {
	if ( isset( $this->error ) ) {
		$error_message  = '<p>' . $this->error->get_error_message() . '</p>';
		$error_message .= '<p class="hide-if-no-js"><button class="button try-again">' . __( 'Try Again' ) . '</button></p>';
		wp_admin_notice(
			$error_message,
			array(
				'additional_classes' => array( 'inline', 'error' ),
				'paragraph_wrap'     => false,
			)
		);
		?>
	<?php } else { ?>
		<div class="no-plugin-results"><?php _e( 'No plugins found. Try a different search.' ); ?></div>
		<?php
	}
}