| 1 |
<?php |
| 2 |
|
| 3 |
/** |
| 4 |
* Theme: Classic. |
| 5 |
* |
| 6 |
* @link https://plugins360.com |
| 7 |
* @since 1.0.0 |
| 8 |
* |
| 9 |
* @package Automatic_YouTube_Gallery |
| 10 |
*/ |
| 11 |
|
| 12 |
$data_params = array( |
| 13 |
'player_title' => (int) $attributes['player_title'], |
| 14 |
'player_description' => (int) $attributes['player_description'] |
| 15 |
); |
| 16 |
|
| 17 |
$featured_video = $videos[0]; // Featured Video |
| 18 |
$featured_video_title = ayg_get_player_title( $featured_video, $attributes ); // Featured Video Title |
| 19 |
$featured_video_description = ayg_get_player_description( $featured_video, $attributes ); // Featured Video Description |
| 20 |
?> |
| 21 |
|
| 22 |
<div class="ayg ayg-theme-single" data-params='<?php echo wp_json_encode( $data_params ); ?>'> |
| 23 |
<!-- Player --> |
| 24 |
<div class="ayg-player"> |
| 25 |
<?php the_ayg_player( $featured_video, $attributes ); ?> |
| 26 |
|
| 27 |
<?php if ( ! empty( $featured_video_title ) || ! empty( $featured_video_description ) ) : ?> |
| 28 |
<div class="ayg-player-caption"> |
| 29 |
<?php if ( ! empty( $featured_video_title ) ) : ?> |
| 30 |
<h2 class="ayg-player-title"><?php echo esc_html( $featured_video_title ); ?></h2> |
| 31 |
<?php endif; ?> |
| 32 |
|
| 33 |
<?php if ( ! empty( $featured_video_description ) ) : ?> |
| 34 |
<div class="ayg-player-description"><?php echo wp_kses_post( make_clickable( $featured_video_description ) ); ?></div> |
| 35 |
<?php endif; ?> |
| 36 |
</div> |
| 37 |
<?php endif; ?> |
| 38 |
</div> |
| 39 |
</div> |
| 40 |
|