We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
abstract class Post_Type
Para crear nuevos post types debemos crear una clase extendida de WASP\Posts\Post_Type.
WASP\Posts\Post_Type
<?php use WASP\Posts\Post_Type; class My_Plugin_Custom_Post_Type extends Post_Type { function __construct() { parent::__construct(); // CPT slug $this->post_type = 'my-cpt-slug'; // CPT labels $this->labels = array( ... ); // CPT arguments $this->args = array( ... ); } } new My_Plugin_Custom_Post_Type;
La propiedad labels hace referencia a $args['labels'] en la función register_post_type(), args al resto de los argumentos pasados a esta función.
labels
$args['labels']
register_post_type()
args