For all who have the problem just with WordPress Blocks/Gutenberg, here is the solution I was looking for a long time.
When you create a new taxonomy, make sure you’ve set show_in_rest
to true
. Otherwise it will not appear in Block editor.
https://developer.wordpress.org/reference/functions/register_taxonomy/
Whether to include the taxonomy in the REST API. Set this to true for the taxonomy to be available in the block editor.
register_taxonomy(
'new-category',
'post',
[
'public' => false,
'rewrite' => false,
'show_ui' => true,
'show_in_rest' => true,
'hierarchical' => true,
]
);
Related Posts:
- Custom Theme Want To Remove One Category From All Displays
- How show categories in admin and get that selected to show posts in index
- Mismatch between posts count and actual list in admin posts page
- How to get subcategories from category slug?
- Remove current category from post but display all others
- Develop Admin Panel Page
- Showing categories and subcategories with posts
- Change default category when I publish a post
- store posts_id of category into a varable?
- Change post-slug using wordpress API? Change permalink of a post using php / jquery?
- How to display two random-post sections that are each under their own category
- How can you display all sibling categories to a post?
- Loop doesn’t exclude the specified category in home page
- Display posts of specific category term
- Widget that shows categories with posts numbers
- How to create a sub post?
- Post Image not displaying in category view
- How do I show posts from another wordpress installation?
- get posts from Custom Post Type & Category
- Category page when using static front page
- Fast publishing in wordpress
- Latest posts by category — how to exclude current post?
- Which file do I need to edit the All Posts page in the admin area?
- How do I include the category next to the title of a post?
- Relative number of post in category
- How to create a “latest news” page showing a list of posts from blog category
- WordPress bulk category select when publishing post
- Exclude some categories from listing on the current post
- How to show a custom taxonomy in the theme?
- How to import nested categories from XML file?
- How do you search for a post or page with a certain url on the WordPress admin panel?
- how to hide empty fields of post category description?
- how can i display my posts alphabetically?
- if in category but only with post meta
- How to get post with associated categories and tags names instead of ids with rest api?
- How to get the old WordPress Draft Editor view back with the Word count?
- Change the color of the Password Protected Post titles
- Display a mixed list of posts and media
- Migrate posts from category and sub-category via SQL
- Parent category / child category posts
- Posts Missing in Dashboard after update
- How to enable custom Shortcodes in Post Category Description? [duplicate]
- Sort by last word in title
- Display post number by category
- singular posts using archive styling
- Bolding several words at once
- Change Post Title For Specific Category
- Display selected categories onto post page
- How to call posts under a specific category on static front page?
- Give posts a particular template based on the assigned category
- How to have more than one page for your posts if you have 8 posts but can store max 4 on a page
- Extract wordpress posts content and category content
- Un-highlight Blog Menu Item when Category Menu Item is Selected
- How to get post with slug and exclude categories
- All categories displays the same posts
- Having pages after specifying post_type post
- Unable to differentiate between two categories under custom post type on single.php
- In what context should Categories and Tags be used
- Exclude post category in a blog page
- Show posts on front page only
- list posts from two categories on a page – plugin not working
- Retrieving posts by their date and category
- Get latest post from categories
- How to create a playlist for audio associated with posts per category
- Are post, page and category IDs unique to each other?
- Change the background of each post according to the category
- Static pages not working
- Post-Archive like a page in a specific subdirectory
- Programmatically add posts from specific category to menu
- WP_Query of Category Not Showing First Post
- Sort All Posts by Category Name in the Admin Panel?
- Post is in descendant category not working in home.php
- WordPress displays post on subcategory only
- How to get posts ordered by using their categories?
- Remove Featured Image from posts in specific category?
- How to show a featured image inside a post in only 1 single category
- Hide parts of the post content after typing it’s name or searching it by category
- List latest posts with least comments in WP-Admin
- SQL Bulk Move old posts by one author to another category
- How to display only one category in a custom post type?
- load more posts by category
- Lightbox on wordpress post page
- Get post category as a separate string and url
- Get only X number of categories
- Display Related Posts by Category in Random
- inserting a category into post
- Getting posts from some categories plus some individual posts
- Change layout of post depending on category
- How to make posts being uncategorized
- How to show category based post in home page?
- How to display a single(current) post from a category
- Sidebar limiting to 10 posts?
- posts going to 2 pages/categories only show up in 1
- displaying the categories post
- How to show beneath posts the full category path?
- What’s a theme that properly handles previews of different types of posts?
- Display Parent Category of a Post belonging only to Subcategory
- How to view all posts (on site, not admin) that are uncategorized?
- How to create a list of links to post with specific category
- How to list post as buch of category, and all of them