wp_get_split_term( int $old_term_id, string $taxonomy ): int|false

Gets the new term ID corresponding to a previously split term.


$old_term_id int Required
Term ID. This is the old, pre-split term ID.
$taxonomy string Required
Taxonomy that the term belongs to.

Top ↑


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.

Top ↑


File: wp-includes/taxonomy.php. View all references

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;

Top ↑


Version Description
4.2.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.