- This topic has 5 replies, 2 voices, and was last updated 4 years, 7 months ago by
Ying.
-
AuthorPosts
-
July 27, 2021 at 8:01 am #1873104
Paul
Hi,
What’s the difference between post category, post tag and post category archive, post tag archive?
Is there a document that describes each location and where an element would apply front-end?
Thanks,
Paul.July 27, 2021 at 9:44 am #1873225Ying
StaffCustomer SupportHi Paul,
The terms like post category/tag, archives are actually defined by WordPress, it’s not a GP thing.
In WordPress, the term ‘Archives’ is used for a list of entries from a post type or taxonomy (like categories and tags).
The post category/tag applies to the single post that belongs to this specific category/tag.
Here’s a visual hook guide for all GP hooks:
https://docs.generatepress.com/article/hooks-visual-guide/Let me know if you need further assistance 🙂
July 27, 2021 at 2:15 pm #1873515Paul
Hi Ying,
I understand the terms are defined by WordPress, I just couldn’t get a test block to display using ‘category’ or ‘tag’ on a single post. Archives are no problem.
It’s not an issue if I won’t need them, I was just trying to understand the trigger.
Thanks,
Paul.July 27, 2021 at 3:27 pm #1873565Ying
StaffCustomer SupportAs you can see, there’s a bold title for each section to indicate it’s for posts or archives:
https://www.screencast.com/t/q2iVf3RXRXYwCan you tell me which hook you are using for the single post and it doesn’t work?
Let me know 🙂
August 6, 2021 at 9:47 am #1886476Paul
Hi,
As an example – I have dummy post setup in ‘Example Category A’. Create a block element, page hero, add dynamic text ‘term meta’, and meta field name ‘category’. Hero displays but without text.
Tag and author archive heros seem fine, category I’m getting something wrong on.
That said, I still don’t understand the difference between ‘post category’ and ‘post category archive’ as a location.
Same for ‘post tag’ or ‘post tag archive’, although I have tag heros displaying ok.Thanks,
Paul.August 6, 2021 at 10:20 am #1886496Ying
StaffCustomer SupportThe location means where you want the element to display.
For example, if you choose post category > example category A, the element will display in single posts which belong to example category A.
If you choose post category archive > example category A, the element will display in the archive page of example category A.
As an example – I have dummy post setup in ‘Example Category A’. Create a block element, page hero, add dynamic text ‘term meta’, and meta field name ‘category’. Hero displays but without text.
Try
list of terms>categoryinstead.Here’s a list of dynamic-content-related videos, hope it will help you to understand the concept better:
https://www.youtube.com/c/GeneratePress/search?query=dynamic -
AuthorPosts
- You must be logged in to reply to this topic.