This repository was archived by the owner on May 6, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathcontent-portfolio-media.php
More file actions
66 lines (51 loc) · 2.02 KB
/
content-portfolio-media.php
File metadata and controls
66 lines (51 loc) · 2.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
/**
* The file is for displaying the single portfolio media
* It is called via single-portfolio.php
*
* @package Bricks
* @link https://themebeans.com/themes/bricks
*/
$portfolio_type_gallery = get_post_meta( $post->ID, '_bean_portfolio_type_gallery', true );
$portfolio_type_audio = get_post_meta( $post->ID, '_bean_portfolio_type_audio', true );
$portfolio_type_video = get_post_meta( $post->ID, '_bean_portfolio_type_video', true );
$gallery_layout = get_post_meta( $post->ID, '_bean_gallery_layout', true );
$orderby = get_post_meta( $post->ID, '_bean_portfolio_randomize', true );
$orderby = ( $orderby == 'off' ) ? 'post__in' : 'rand';
$audio_mp3 = get_post_meta( $post->ID, '_bean_audio_mp3', true );
$embed = get_post_meta( $post->ID, '_bean_portfolio_embed_code', true );
$embed2 = get_post_meta( $post->ID, '_bean_portfolio_embed_code_2', true );
$embed3 = get_post_meta( $post->ID, '_bean_portfolio_embed_code_3', true );
$embed4 = get_post_meta( $post->ID, '_bean_portfolio_embed_code_4', true );
if ( ! post_password_required() ) {
if ( $portfolio_type_audio == 'on' ) {
if ( $audio_mp3 ) {
bean_audio( $post->ID );
}
}
if ( $portfolio_type_gallery == 'on' ) {
bean_gallery( $post->ID, 'port-full', $gallery_layout, $orderby, true );
}
if ( $portfolio_type_video == 'on' ) {
if ( $embed ) {
echo '<div class="video-frame">';
echo stripslashes( htmlspecialchars_decode( $embed ) );
echo '</div>';
} //END if($embed)
if ( $embed2 ) {
echo '<div class="video-frame">';
echo stripslashes( htmlspecialchars_decode( $embed2 ) );
echo '</div>';
} //END if($embed2)
if ( $embed3 ) {
echo '<div class="video-frame">';
echo stripslashes( htmlspecialchars_decode( $embed3 ) );
echo '</div>';
} //END if($embed3)
if ( $embed4 ) {
echo '<div class="video-frame">';
echo stripslashes( htmlspecialchars_decode( $embed4 ) );
echo '</div>';
}
}
}