public function setup() {
		parent::setup();

		// Remove post type support and meta boxes.
		$this->remove_post_type_support();

		// Add support for displaying information in publish box from a page type.
		if ( method_exists( $this, 'publish_box' ) ) {
			add_action( 'post_submitbox_misc_actions', [$this, 'publish_box'] );
		}

		// Hide page template dropdown if it shouldn't be showed.
		if ( ! $this->show_page_template ) {
			add_filter( 'theme_page_templates', '__return_empty_array' );
		}

		// Main title input placeholder.
		if ( ! empty( $this->labels['title_placeholder'] ) ) {
			add_filter( 'enter_title_here', function () {
				return $this->labels['title_placeholder'];
			} );
		}
	}
public function setup() {
		parent::setup();

		// Remove post type support and meta boxes.
		$this->remove_post_type_support();

		// Add support for displaying information in publish box from a page type.
		if ( method_exists( $this, 'publish_box' ) ) {
			add_action( 'post_submitbox_misc_actions', [$this, 'publish_box'] );
		}

		// Hide page template dropdown if it shouldn't be showed.
		if ( ! $this->show_page_template ) {
			add_filter( 'theme_page_templates', '__return_empty_array' );
		}

		// Main title input placeholder.
		if ( ! empty( $this->labels['title_placeholder'] ) ) {
			add_filter( 'enter_title_here', function () {
				return $this->labels['title_placeholder'];
			} );
		}
	}
public function setup ( ) { parent :: setup ( ) ; // Remove post type support and meta boxes. $ this -> remove_post_type_support ( ) ; // Add support for displaying information in publish box from a page type. if ( method_exists ( $ this , 'publish_box' ) ) { add_action ( 'post_submitbox_misc_actions' , [ $ this , 'publish_box' ] ) ; } // Hide page template dropdown if it shouldn't be showed. if ( ! $ this -> show_page_template ) { add_filter ( 'theme_page_templates' , '__return_empty_array' ) ; } // Main title input placeholder. if ( ! empty ( $ this -> labels [ 'title_placeholder' ] ) ) { add_filter ( 'enter_title_here' , function ( ) { return $ this -> labels [ 'title_placeholder' ] ; } ) ; } }
Setup page type.
Setup page type .