1

I'm looking for a function to rename the default 'Uncategorized' category. The reason I need this is because I'm running a WordPress multi-site largely used by users with little technical knowledge and only allows the one, default category for their blog.

2
  • I am not at all familiar with multi-site but will changing it under settings work? Settings -> Writing -> Default Post Category ? I suppose another option would be to physically rename the category by editing it under Categories.
    – Howdy_McGee
    Commented Feb 26, 2014 at 21:23
  • Not for this purpose it will not. Commented Feb 26, 2014 at 21:34

1 Answer 1

2

I think wp_update_term should do the trick:

wp_update_term(1, 'category', array(
  'name' => 'A Real Category Name',
  'slug' => 'real-category-name'
));

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.