Uses
Uses | Description |
---|---|
wp-includes/taxonomy.php: wp_get_split_terms() | Get data about terms that previously shared a single term_id, but have since been split. |
Get the new term ID corresponding to a previously split term.
(int) (Required) Term ID. This is the old, pre-split term ID.
(string) (Required) Taxonomy that the term belongs to.
(int|false) If a previously split term is found corresponding to the old term_id and taxonomy, the new term_id will be returned. If no previously split term is found matching the parameters, returns false.
File: wp-includes/taxonomy.php
function wp_get_split_term( $old_term_id, $taxonomy ) { $split_terms = wp_get_split_terms( $old_term_id ); $term_id = false; if ( isset( $split_terms[ $taxonomy ] ) ) { $term_id = (int) $split_terms[ $taxonomy ]; } return $term_id; }
Version | Description |
---|---|
4.2.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/wp_get_split_term