$term, 'taxonomy' => 'aiopod_participants', 'placeholder' => AIOPOD_PLUGIN_PLACEHOLDER_AVATAR_URL ) ); // Build tab URLs $base_url = aiopod_get_participant_page_url( $term ); $podcasts_url = remove_query_arg( 'view', $base_url ); $episodes_url = add_query_arg( 'view', 'episodes', $base_url ); // Get active tab $allowed_views = array( 'podcasts', 'episodes' ); $current_view = get_query_var( 'view' ); $active_tab = in_array( $current_view, $allowed_views ) ? $current_view : 'podcasts'; // Podcasts HTML $podcasts = ''; if ( ! empty( $attributes['show_podcasts'] ) ) { $podcasts_args = array( 'participants' => $term->term_id, 'echo' => 0 ); $podcasts_args = apply_filters( 'aiopod_single_participant_podcasts_args', $podcasts_args ); $podcasts = aiopod_the_podcasts( $podcasts_args ); } // Podcasts title $podcasts_title = trim( $attributes['podcasts_title'] ); if ( '' === $podcasts_title ) { $podcasts_title = __( 'Podcasts', 'aio-podcast-studio' ); } // Episodes HTML $episodes = ''; if ( ! empty( $attributes['show_episodes'] ) ) { $episodes_args = array( 'participants' => $term->term_id, 'echo' => 0 ); $episodes_args = apply_filters( 'aiopod_single_participant_episodes_args', $episodes_args ); $episodes = aiopod_the_episodes( $episodes_args ); } // Episodes title $episodes_title = trim( $attributes['episodes_title'] ); if ( '' === $episodes_title ) { $episodes_title = __( 'Episodes', 'aio-podcast-studio' ); } ?>