Recent

wz_get_all_parent_ids function

wz_get_all_parent_ids()

Get all parent term_taxonomy_ids for a given array of term_taxonomy_ids.

Source: includes/wz-pluggables.php line 103

Signature

function wz_get_all_parent_ids( $term_taxonomy_ids, $levels = ... ): int[];

Parameters

TypeNameDescription
int|int[]$term_taxonomy_idsArray of term_taxonomy_ids or a single term_taxonomy_id.
string$levelsUse ‘all’ for ancestors, ‘parent’ for the immediate parent.

Returns

int[] — Array of all parent term_taxonomy_ids merged with $term_taxonomy_ids.