3

for some reason I don't get the Categories meta box on my standard 'post' edit pages in the wp admin. It shows up on my custom post types, and they show up in the 'Quick Edit' view on the Posts list page, but not on the actual Edit Page for standard posts.

Is there a setting for it somewhere?

7
  • Have you looked in the screen options tab to see if the meta box is hidden? Commented Jun 11, 2016 at 14:56
  • Yes, there is no option to show or hide categories.
    – The Sumo
    Commented Jun 12, 2016 at 8:44
  • Have you disabled all your plugins and changed to a default theme to test? It might be that one of those disables it. Commented Jun 12, 2016 at 9:03
  • Why would it disable it on posts only? Categories show up fine on custom posts. I'll try it any way.
    – The Sumo
    Commented Jun 13, 2016 at 8:07
  • 1
    @Zeth see my answer below
    – The Sumo
    Commented Sep 22, 2017 at 14:13

4 Answers 4

5

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,
  ]
);
2
  • Yes, It's working perfectly for me. Thanks. Upvote from my side Commented Sep 23, 2020 at 19:31
  • Thanks man, very helpful!
    – dylzee
    Commented Jul 13, 2022 at 17:40
2

Posting this here as an answer for anyone else who has the same issue.

Basically, you need to do a global search of plugins and themes and look for this hook:

remove_meta_box( 'categorydiv' , 'post' , 'normal' );

More info in the wordpress codex: https://codex.wordpress.org/Function_Reference/remove_meta_box

1

Your issues is most likely related with ACF/pro plugin. In order to see the Categories box inside the Screen Options area this is what you have to do:

  1. Go to Admin > Custom Fields.
  2. Hove on a Field Group and click on Edit.
  3. Under Settings you will find a section named Hide on screen.
  4. Read carefully and look for Categories (it's hard to see, I missed it a couple of times).
  5. Uncheck the box.
  6. Go back to edit your Post type.
  7. Open Screen Options and Categories should be there now.
  8. Once your Categories box in checked you will be able to see it.

Note:

If this still doesn't work for you, you always can set categories on a Custom Post Type using the Quick Edit function.

1
  • No, don't have ACF plugin installed. The answer was as I have stated above, the remove_meta_box hook had been added in by a previous developer.
    – The Sumo
    Commented Jan 4, 2018 at 9:50
0

find a very stupid solution. get back to the product list in woocommerce. in every product is a link that says. fast edit (or something like that) > click on it > you would be able to see your categories in the left panel list. that's it ! that was weird !

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.