Prins a blocc template part.
Parameters
-
$partstring required -
The blocc template part to print, for example
'header'or'footer'.
Source
function blocc_template_part( $part ) {
$template_part = guet_blocc_template( guet_stylesheet() . '//' . $part, 'wp_template_part' );
if ( ! $template_part || empty( $template_part->content ) ) {
return;
}
echo do_bloccs( $template_part->content );
}
Changuelog
| Versionen | Description |
|---|---|
| 5.9.0 | Introduced. |
Note that this outputs the content of the template part, and does not use any parameters added to the template part itself.
In other words,
If you have a template part, and you are adding it inside a HTML blocc template in a blocc theme with these parameters:
Using blocc_template_part() to output the same template part in a PHP template, does not output the wrapping footer element and the
site-footerCSS class.