get_{$adjacent}_post_excluded_terms

get_{$adjacent}_post_excluded_terms

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: wordpress-6.5.2

apply_filters('get_{$adjacent}_post_excluded_terms') is found 1 times:

  • /wp-includes/link-template.php line 1864
    	 * @since 4.4.0
    	 *
    	 * @param int[]|string $excluded_terms Array of excluded term IDs. Empty string if none were provided.
    	 */
    	$excluded_terms = apply_filters( "get_{$adjacent}_post_excluded_terms", $excluded_terms );
    
    	if ( $in_same_term || ! empty( $excluded_terms ) ) {
    		if ( $in_same_term ) {
    			$join  .= " INNER JOIN $wpdb->term_relationships AS tr ON p.ID = tr.object_id INNER JOIN $wpdb->term_taxonomy AS tt ON tr.term_taxonomy_id = tt.term_taxonomy_id";
    			$where .= $wpdb->prepare( 'AND tt.taxonomy = %s', $taxonomy );