Recently in the development of a WordPress website, the project needs to show a "case show" module, where each case belongs to a different industry category, such as "medical", "education", "real estate" and so on. "Medical", "Education", "Real Estate" and so on. I used register post type() to register a custom post type named case to store these contents. However, when editing these case posts in the backend, I found that there is no place to add an industry category for the case.
While it's possible to add taxonomies via a plugin, in order to keep the code light and manageable, I'd like to implement taxonomy registration manually in code. This leads to a specific question:How do I add a taxonomy to a custom post type without using a plugin?
No comments