I think wp_update_term
should do the trick:
wp_update_term(1, 'category', array(
'name' => 'A Real Category Name',
'slug' => 'real-category-name'
));
Related Posts:
- Get rid of WordPress category, tag and author archives?
- How to add the category ID to admin page
- How to create a widgetized sidebar for every category dynamically?
- Only show category to certain user levels without plugin
- List Categories of the Parent Category of the Current Category
- exclude category from WordPress Form function
- wp_list_categories, Add class to all list items with children
- Remove “Parent” Selection When Adding/Editing Categories?
- Check is category parent or not from its ID
- How to show in search results posts with a particular tag in a particular category?
- How can I get an tag to wrap each ancestor that gets outputted in this condition?
- If category is in parent category?
- If in category to be inside of a function
- Check child/parent categories if exists
- Getting URL of archive (category) page
- How to show only one category in breadcrumb navigation
- Query posts from category based on a filter most favorited
- Add tag parameter to category.php
- Random Featured Image Based on Category
- add slug beside name in Admin Category Checklists
- Change div background acording to the selected category
- How to use wp_list_categories with plugin category?
- Redirect depending on category chosen
- How to add icon over specific thumb
- How to load several hierarchical categories from functions.php
- Change Default Content when Creating a Post based on Previous Category Choice
- How to add a custom thumbnail size for a specific category?
- create function to call category name and slug
- Different size video display for category page (smaller) & detail page (larger)
- Code to display category-specific single.php is overriding normal single.php, too
- Loop Through Categories in Custom Field
- Function to list posts from current post’s category fails in WP 3.8
- Show only one category in main query, issues on tag page
- Show parent-child relationship for categories in the wordpress admin
- How To Find Out WordPress Category Table in MYSQL?
- Add custom field to Category
- Does the ‘cat’ argument in query_posts fetch posts from subcategories as well as the given ID?
- Get Default Post Category From Settings
- Are Categories, Tags and Custom Taxonomies any different in regards to SEO?
- Display list of Sub-Categories and the posts they contain, within one main Category
- Create subdomains for tags and categories
- Categories – create a new separate set right after the default?
- How to get this only in small letters (lowercase)? [closed]
- How to totally get rid of Category in my blog?
- Is there a function to cause empty categories not to show in menus?
- Category Specific Archive
- How to select product category while adding new product in woocommerce? [closed]
- How do I count how many top level categories there are?
- How to get the number of child categories a specific parent category has?
- Removing category base form links messes up the parent-child behavior
- display most popular tags of category?
- Exclude category from loop not working
- How to list only child categories?
- Want to hide some categories from the categories meta box in the post editor for the two specific user roles
- Cannot add / edit categories to a post anymore
- List archived posts by subcategory
- What’s the Simplest Way to Override/Rewrite the %category% Permalink Structure Tag?
- How to get category name from URL and pass to a template
- Displaying multiple loops based off of category
- Display Categories, Sub-categories, and Sub-sub-categories on separate pages
- WooCommerce IF statements not working
- Hide woocommerce category name from specific pages
- There any way to get de percentage of number of post by user and category?
- How to display categories which contains particular tag?
- category permalinks
- Displaying Child Categories in carousel
- Removing Uncategorized on post save if other category present?
- Is there an easy way to get a list of Category IDs?
- How to customize my category pages
- Remove “Browsed by Category” from Category Page
- Not showing list if there aren’t any categories to display
- How to list all categories and their IDs using SQL query?
- How to display a value inside a post with a specified category from a category custom field? [closed]
- Apply WordPress function on specific woocommerce product categories only
- display specific category on page
- How to let the user create a selection of categories via the backend
- Display subcategories selectbox on each category page
- Media (images, videos, etc.) not showing on Category page
- Problem with Custom Post Type Categories
- Display post thumbnail for specific category outside the loop
- PHP dynamical conditional post display
- can I ‘combine’ categories as a menu item?
- Displaying categories in different template problem
- List taxonomy terms assigned to a post in hierarchical view
- Show the parent taxonomy by creating shortcode in woocommerce?
- Get_term_meta() does not work with pre_get_posts()
- i can’t use wordpress functions in ajax loaded php file
- How can I exclude a particular category from my WordPress Page 1 and Page 2?
- Categories and Tags Conflict after Woocommerce Installation
- how to display categories for a specific post?
- the_content() not showing full posts in category template
- Show parent category if there is no subcategory
- Add category links?
- show posts found in multiple categories via category_name query string?
- Add html word before category
- How to get tags and categories?
- Display last postings of 5 categories on homepage
- Category that can hold only specific number of post
- How to add the sidebar in all category page
- Print child category slug nicename