plugin-icon

Primary Cat

제작자: Web Guy·
Set a primary category for your posts... and then do stuff with it. [primary-cat]
버전
0.2
최근 업데이트일
Sep 1, 2025
Primary Cat

Set a primary category for your posts… and then do stuff with it.

Why would I want a primary category?

Out of the box, WordPress allows you to assign multiple categories to a post. Unless you’re enforcing a strict one-category-per-post-only rule for your website, this can be a problem now for displaying the most important category for your respective posts, as opposed to WordPress automatically selecting it for you.

Let’s say that your blog is about animals, and you publish an article titled “Why Do Dogs Love Water and Cats Hate It?” with the categories: Cats, Dogs, and Pets assigned to it.

By default, anywhere that WordPress might display a single category to represent the post, it’s probably going to display Cats by default, but since the post is equally about both cats and dogs, maybe the more general Pets category would be more appropriate.

This plugin allows you to accomplish that, whether it’s for presentational, structural, organizational, SEO, or all of the above purposes.

In what ways can I utilize a primary category?

[primary-cat]

In any creative way that you can imagine, but here are some examples I thought of:

  • To present the main category that the post belongs to above its title (by adding <?php echo do_shortcode( '[primary-cat]' ); ?> in your theme code, child theme, or custom functions plugin), in some aesthetic way (which can be styled with CSS .primary-cat). Lots of blog, news, and magazine sites have this feature.
  • To have the appropriate slug in your post URLs if you’re using the custom /%category%/%postname%/ permalink structure under Settings > Permalinks.
  • To have breadcrumbs (by using the shortcode [primary-bread]) on your site for user-friendliness (which can be styled with CSS #breadcrumbs), and can in turn, also improve SEO.
무료Business 요금제에서
설치하면 WordPress.com 서비스 약관서드파티 플러그인 약관에 동의하게 됩니다.
테스트된 버전
WordPress 6.8.3
이 플러그인은 다운로드할 수 있으며 에서 사용할 수 있습니다.