How to get all template files used for rendering a single post/page?
So, I need to debug an issue and I would like to see all template files that were used to render this specific page. I mean specific sub template files (not the main .php file), like sub woocommerce template files.
For the main template file this works:
add_action( 'wp_footer', function() {
global $template;
print_r( $template );
});
I get the main (last) template file used (eg. single.php).
But I would really like to see all templates embedded with eg. wc_get_template / get_template_part. I just don't have an idea how to achieve that.
Does someone have an idea on how to do this?
Topic get-template-part templates Wordpress
Category Web