bear
June 10, 2025, 3:13am
1
Create a custom post ‘Test’ with Metabox
We added category ‘category1, category2’ to ‘test’ post with Metabox.
Category 1 and Category 2 specified different templates.
The result is the same template that specified category1 or category2.
Is this an error?
What is the solution?
Or is the designation method wrong?
The way I set it is
Template Name: Test - caregoty1
Post Template type: Archive
Post Template Conditions : post type - test, Terms - category1
Template Name: Test - caregoty2
Post Template type: Archive
Post Template Conditions : post type - test, Terms - category2
Oh, by the way, the bricks version is 2.0.
timmse
June 10, 2025, 11:02am
2
Hi JongYoung,
Thanks so much for your report!
I assume that you are confusing single post templates and archive templates (?). Your template conditions apply to the term archive and usually list the posts that are assigned to the corresponding terms.
Perhaps a look at the WordPress template hierarchy will help you to see what is possible and what is not?
As discussed, template files are modular, reusable files, used to generate the web pages on your WordPress site. Some template files (such…
Best regards,
timmse
bear
June 13, 2025, 2:50am
3
It’s confusing.
Even if I check WordPress Hierarchy, it is difficult to understand exactly.
For example, ‘post type = test1’ made from the metabox plug-in.
And there are two categories in test1. (category1, category2)
Users have issued 2 posts.
post1(test1, category1)
post2(test1, category2)
How can I get different templates to be applied?
timmse
June 16, 2025, 6:56am
4
Yes, it can be confusing
Different templates for what? The single post? Or the term archive?