WP_Post_Type::__construct

SummerySummery

Constructor.

Syntax

WP_Post_Type::__construct( string $post_type, array|string $args = array() )

DescriptionDescription

Will populate object properties from the provided arguments and assign other default properties based on that information.

ParametersParameters

$post_type

(string) (Required) Post type key.

$args

(array|string) (Optional) Array or string of arguments for registering a post type.

Default value: array()

SourceSource

File: wp-includes/class-wp-post-type.php


			

ChangelogChangelog

Changelog
Version Description
4.6.0 Introduced.

See alsoSee also

Scroll to Top