![Matrix Style Image Representing WordPress Code Snippet](https://purelysupp.com/wordpress/wp-content/uploads/sites/2/2022/09/matrix-source-code-1024x576.jpg)
Add the following code to your theme’s function.php file, or a functionality plugin to load a template file for a Custom Post Type.
function be_products_template( $template ) {
if( is_tax( array( 'products_category', 'products_tag' ) ) )
$template = get_query_template( 'archive-products' );
return $template;
}
add_filter( 'template_include', 'be_products_template' );
Share Your Two Cents