
Adding a taxonomy metabox to a new type
Adding a taxonomy metabox to a new type. Metabox appears with tags and categories, which have already been used. Text CUSTOM_POST_TYPE must be replaced with the record type name, which you created.
1 2 3 4 | function reg_cat() { register_taxonomy_for_object_type('category','CUSTOM_POST_TYPE'); } add_action('init', 'reg_cat'); |
Checked everything and everything works. Good luck developing your own data types, for WordPress and plugins that will use these custom types.

/*

- Basic web design course;
- Site layout;
- General course on CMS WordPress and continuation of the course on template development;
- Website development in PHP.