A category’s name, description and post count
wp="term-title" Every WordPress category already has a name, a description and a post count. These values show them in the header of the category page: one design, and “Coffee”, “Kitchen” and “Events” each get their own text.
Where it goes
On archive.html: it builds the template WordPress uses to show categories and tags.
wp="term-title" goes on the heading, wp="term-desc" on the block for the description, wp="term-count" on the element with the number of posts.
Example: the header of the “Coffee” category
<header class="category">
<h1 wp="term-title">Coffee</h1>
<div class="category__lead" wp="term-desc">
<p>Beans, brewing and the people who roast them.</p>
</div>
<p class="category__count"><span wp="term-count">12</span> posts</p>
</header>Beans, brewing and the people who roast them.
14 posts
The client changed the category’s description, and the header of its page changed with it.
What matters
- The name and description are edited in Posts → Categories, on the category itself; WordPress counts the posts.
- On a
<div>the description comes in paragraphs, the way WordPress split it; on a<p>or a heading it is plain text without paragraphs. - On pages that are not a category or tag page, these values print nothing.
wp="archive-title"prints the name too, but with the WordPress prefix: “Category: Coffee”.
Common mistakes
The build log is the “Logs” tab of your project on themeforge.pro; the free markup check shows the same notes.
<h1 wp="post-title">Coffee</h1>wp="post-title" in the category header: the name is replaced by the title of a post from the list below. The log stays silent.
<h1 wp="term-title">Coffee</h1>wp="term-title".
Alternative spelling
wp="term_title" works the same: the build gives an identical theme.