Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Is there a way to use the register_taxonomy function to create child taxonomies to a specific parent taxonomy in a hierarchical structure?

For example: Let's say I'm creating a theme for selling cars where users can activate it and it automatically creates a hierarchical taxonomy called "Make". Is there any way to have it automatically create a few different vehicle "make" taxonomies, say Toyota, Lexus, etc.?

share|improve this question
add comment

1 Answer 1

up vote 3 down vote accepted

I think you mean you want to create terms in your taxonomy?

Have a look at this answer for detecting when a theme is activated.

Then use wp_insert_term to insert the terms into your taxonomy.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.