Building a plugin… and I have an array that loops through wp_insert_term to create a bunch of terms for my taxonomy. Because they are in the correct order in the array, I can callback to get the parent id and use it to form a parent/child relationship.
These relationships are formed, and can be found in the database, but using get_terms doesn’t provide the children UNLESS I create 1 child the old fashioned way in the dashboard.
What happens when I create a term in the dashboard editor that finishes the installation of my taxonomy plugin? And how can I fix it…
- The topic ‘wp_insert_term trouble creating parent/child relationships’ is closed to new replies.