Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: render_block_core_template_part_file

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
81                      * Fires when a block template part is loaded from a template part in the theme.
82                      *
83                      * @since 5.9.0
84                      *
85                      * @param string $template_part_id        The requested template part namespaced to the theme.
86                      * @param array  $attributes              The block attributes.
87                      * @param string $template_part_file_path Absolute path to the template path.
88                      * @param string $content                 The template part content.
89                      */
90                     do_action( 'render_block_core_template_part_file', $template_part_id, $attributes, $template_part_file_path, $content );
91                } else {
92                     /**
93                      * Fires when a requested block template part does not exist in the database nor in the theme.
94                      *
95                      * @since 5.9.0
96                      *
97                      * @param string $template_part_id        The requested template part namespaced to the theme.
98                      * @param array  $attributes              The block attributes.
99                      * @param string $template_part_file_path Absolute path to the not found template path.