wp_set_post_cats()
Deprecated. It is no longer supported and may be removed in future releases. Use wp_set_post_categories() instead.
Sets the categories that the post ID belongs to.
No Hooks.
Returns
true|false|Mixed.
Usage
wp_set_post_cats( $blogid, $post_id, $post_categories );
- $blogid(int)
- Not used.
Default:'1' - $post_id(int)
- .
- $post_categories(array)
- .
Default:array()
Notes
Changelog
| Since 1.0.1 | Introduced. |
| Deprecated since | 2.1.0 |
| Deprecated | Use wp_set_post_categories() |
wp_set_post_cats() wp set post cats code WP 6.9.1
function wp_set_post_cats($blogid = '1', $post_id = 0, $post_categories = array()) {
_deprecated_function( __FUNCTION__, '2.1.0', 'wp_set_post_categories()' );
return wp_set_post_categories($post_id, $post_categories);
}