
如何编辑WordPress代码 – HTML、CSS、PHP
do_action( 'render_block_core_template_part_file', $template_part_id, $attributes, $template_part_file_path, $content )
render_block_core_template_part_file。这个过滤钩子用于修改用于渲染块的核心模板部分的文件路径。该钩子为开发者提供了使用自定义模板部分而不是WordPress提供的默认模板部分的权限。
当一个区块模板部分从主题中的模板部分加载时,就会触发。
do_action( 'render_block_core_template_part_file', $template_part_id, $attributes, $template_part_file_path, $content );