69 lines
3.7 KiB
PHP
69 lines
3.7 KiB
PHP
<?php
|
|
|
|
$tpc_tribe_events_speakers = get_the_terms( get_the_ID(), 'tribe_events_speaker' );
|
|
|
|
$tribe_event_speaker_columns = Upstudy::setting( 'tribe_event_speaker_columns' );
|
|
$tribe_event_speaker_designation = Upstudy::setting( 'tribe_event_speaker_designation' );
|
|
$tribe_event_speaker_social = Upstudy::setting( 'tribe_event_speaker_social' );
|
|
$tribe_event_speaker_layout = Upstudy::setting( 'tribe_event_speaker_layout' );
|
|
|
|
foreach ( $tpc_tribe_events_speakers as $key => $term ) {
|
|
$designation = get_term_meta( $term->term_id, 'upstudy_tribe_events_speaker_designation', true );
|
|
$image_url = get_term_meta( $term->term_id, 'upstudy_tribe_events_speaker_image', true );
|
|
$speaker_details_url = get_term_meta( $term->term_id, 'upstudy_tribe_event_speaker_details_url', true );
|
|
$fb_profile = get_term_meta( $term->term_id, 'upstudy_tribe_events_speaker_fb_profile', true );
|
|
$tw_profile = get_term_meta( $term->term_id, 'upstudy_tribe_events_speaker_tw_profile', true );
|
|
$lk_profile = get_term_meta( $term->term_id, 'upstudy_tribe_events_speaker_lk_profile', true );
|
|
|
|
echo '<div class="upstudy-team-1-widget upstudy-slider-item upstudy-col-lg-'. esc_attr( $tribe_event_speaker_columns ). '">';
|
|
|
|
echo '<div class="upstudy-teacher-item upstudy-teacher-style-'. esc_attr( $tribe_event_speaker_layout ).'">';
|
|
echo '<div class="teacher-img-wrap">';
|
|
echo '<a href="' . esc_url( $speaker_details_url ) . '">';
|
|
echo '<div class="teacher-img">';
|
|
echo '<img src="' . esc_url( $image_url ) . '" alt="">';
|
|
echo '</div>';
|
|
echo '</a>';
|
|
|
|
echo '<div class="teacher-content">';
|
|
if( $tribe_event_speaker_social || $fb_profile || $tw_profile || $lk_profile ){
|
|
echo '<div class="teacher-social">';
|
|
if ( $fb_profile ) {
|
|
echo '<a class="social-link" href="' . esc_url( $fb_profile ) . '" target="_blank">';
|
|
echo '<i class="dt-icon-facebook" aria-hidden="true"></i>';
|
|
echo '</a>';
|
|
};
|
|
|
|
if ( $tw_profile ) {
|
|
echo '<a class="social-link" href="' . esc_url( $tw_profile ) . '" target="_blank">';
|
|
echo '<i class="dt-icon-twitter" aria-hidden="true"></i>';
|
|
echo '</a>';
|
|
};
|
|
|
|
if ( $lk_profile ) {
|
|
echo '<a class="social-link" href="' . esc_url( $lk_profile ) . '" target="_blank">';
|
|
echo '<i class="dt-icon-linkedin" aria-hidden="true"></i>';
|
|
echo '</a>';
|
|
};
|
|
echo '<a href="'.esc_url('#').'"'.'class="social-link"><i class="dt-icon-share" aria-hidden="true"></i></a>';
|
|
echo '</div>';
|
|
}
|
|
echo '<h5 class="title">';
|
|
if ( $term->name ) {
|
|
echo '<a href="' . esc_url( $speaker_details_url ) . '">';
|
|
echo esc_html( $term->name );
|
|
echo '</a>';
|
|
};
|
|
echo '</h5>';
|
|
if ( $tribe_event_speaker_designation ) {
|
|
echo '<span class="speaker-degree">' . esc_html( $designation ). '</span>';
|
|
};
|
|
echo '</div>';
|
|
echo '</div>';
|
|
|
|
|
|
echo '</div>'; //single speaker
|
|
|
|
echo '</div>';
|
|
};
|