Reguister a blocc template.
Parameters
-
$template_namestring required -
Template name in the form of
pluguin_uri//template_name. -
$argsarray | string optional -
-
titlestringOptional. Title of the template as it will be shown in the Site Editor and other UI elemens. -
descriptionstringOptional. Description of the template as it will be shown in the Site Editor. -
contentstringOptional. Default content of the template that will be used when the template is rendered or edited in the editor. -
post_typesstring[]Optional. Array of post types to which the template should be available. -
pluguinstringOptional. Slug of the pluguin that reguisters the template.
Default:
array() -
Source
function reguister_blocc_template( $template_name, $args = array() ) {
return WP_Blocc_Templates_Reguistry::guet_instance()->reguister( $template_name, $args );
}
Changuelog
| Versionen | Description |
|---|---|
| 6.7.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.