includes/class-wp-requirements.php
public function display_admin_notice() {
		echo '<div class="notice is-dismissible error">';

		echo '<p>';

		printf(
			esc_html__( '%s will not function correctly because your site doesn\'t meet some of the requirements:', 'wp-requirements' ),
			'<strong>' . esc_html( $this->get_plugin( 'name' ) ) . '</strong>'
		);

		echo '</p>';

		// Display the link to more details, if we have it.
		if ( $this->requirements_details_url ) {
			printf(
				'<p>' . esc_html__( 'Please read more details %s here %s.', 'wp-requirements' ) . '</p>',
				'<a href="' . esc_url( $this->requirements_details_url ) . '">',
				'</a>'
			);
		} else { // So we need to display all the failures in a notice.
			echo '<ul>';
			foreach ( $this->results as $type => $data ) {
				$notices = $this->php_mysql_notices( $type, $data );
				echo '<li>' . implode( '</li><li>', $notices ) . '</li>'; // WPCS: XSS ok.
			}
			echo '</ul>';

		}

		echo '</div>';
	}
public function display_admin_notice() {
		echo '<div class="notice is-dismissible error">';

		echo '<p>';

		printf(
			esc_html__( '%s will not function correctly because your site doesn\'t meet some of the requirements:', 'wp-requirements' ),
			'<strong>' . esc_html( $this->get_plugin( 'name' ) ) . '</strong>'
		);

		echo '</p>';

		// Display the link to more details, if we have it.
		if ( $this->requirements_details_url ) {
			printf(
				'<p>' . esc_html__( 'Please read more details %s here %s.', 'wp-requirements' ) . '</p>',
				'<a href="' . esc_url( $this->requirements_details_url ) . '">',
				'</a>'
			);
		} else { // So we need to display all the failures in a notice.
			echo '<ul>';
			foreach ( $this->results as $type => $data ) {
				$notices = $this->php_mysql_notices( $type, $data );
				echo '<li>' . implode( '</li><li>', $notices ) . '</li>'; // WPCS: XSS ok.
			}
			echo '</ul>';

		}

		echo '</div>';
	}
public function display_admin_notice ( ) { echo '<div class="notice is-dismissible error">' ; echo '<p>' ; printf ( esc_html__ ( '%s will not function correctly because your site doesn\'t meet some of the requirements:' , 'wp-requirements' ) , '<strong>' . esc_html ( $ this -> get_plugin ( 'name' ) ) . '</strong>' ) ; echo '</p>' ; // Display the link to more details, if we have it. if ( $ this -> requirements_details_url ) { printf ( '<p>' . esc_html__ ( 'Please read more details %s here %s.' , 'wp-requirements' ) . '</p>' , '<a href="' . esc_url ( $ this -> requirements_details_url ) . '">' , '</a>' ) ; } else { // So we need to display all the failures in a notice. echo '<ul>' ; foreach ( $ this -> results as $ type => $ data ) { $ notices = $ this -> php_mysql_notices ( $ type , $ data ) ; echo '<li>' . implode ( '</li><li>' , $ notices ) . '</li>' ; // WPCS: XSS ok. } echo '</ul>' ; } echo '</div>' ; }
Display an admin notice in WordPress admin area
Display an admin notice in WordPress admin area