WP_MS_Themes_List_Table::__construct

Advertisement

Summery Summery

Constructor.

Syntax Syntax

WP_MS_Themes_List_Table::__construct( array $args = array() )

Parameters Parameters

$args

(Optional) An associative array of arguments.

Default value: array()

Source Source

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

	 * @since 3.1.0
	 *
	 * @see WP_List_Table::__construct() for more information on default arguments.
	 *
	 * @global string $status
	 * @global int    $page
	 *
	 * @param array $args An associative array of arguments.
	 */
	public function __construct( $args = array() ) {
		global $status, $page;

		parent::__construct(
			array(
				'plural' => 'themes',
				'screen' => isset( $args['screen'] ) ? $args['screen'] : null,
			)
		);

		$status = isset( $_REQUEST['theme_status'] ) ? $_REQUEST['theme_status'] : 'all';
		if ( ! in_array( $status, array( 'all', 'enabled', 'disabled', 'upgrade', 'search', 'broken', 'auto-update-enabled', 'auto-update-disabled' ), true ) ) {
			$status = 'all';
		}

Advertisement

Changelog Changelog

Changelog
Version Description
3.1.0 Introduced.

See also See also

Advertisement

Leave a Reply