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 pathsingle-portfolio.php
More file actions
76 lines (55 loc) · 1.75 KB
/
single-portfolio.php
File metadata and controls
76 lines (55 loc) · 1.75 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
67
68
69
70
71
72
73
74
75
76
<?php
/**
* The template for displaying the portfolio singular page.
*
* @package Bricks
* @link https://themebeans.com/themes/bricks
*/
get_header();
// META
$gallery_layout = get_post_meta( $post->ID, '_bean_gallery_layout', 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 );
// VIEW COUNTER
bean_setPostViews( get_the_ID() ); ?>
<?php
if ( have_posts() ) :
while ( have_posts() ) :
the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class( $gallery_layout ); ?>>
<div class="primary-sidebar">
<h1 class="entry-title"><?php the_title(); ?></h1>
<div class="entry-content">
<?php the_content(); ?>
</div><!-- END .entry-content-->
<?php if ( ! post_password_required() ) { ?>
<?php get_template_part( 'content', 'portfolio-meta' ); ?>
<?php } //END if ( !post_password_required() ) ?>
</div><!-- END .primary-sidebar -->
<div class="primary-content">
<?php get_template_part( 'content', 'portfolio-media' ); ?>
<?php if ( ! post_password_required() ) { ?>
<?php
$more_loop = get_theme_mod( 'portfolio_more_loop' );
if ( $more_loop != '' ) {
switch ( $more_loop ) {
case 'related':
$terms = get_the_terms( $post->ID, 'portfolio_category' );
if ( $terms && ! is_wp_error( $terms ) ) :
get_template_part( 'content', 'portfolio-related' );
endif;
break;
case 'more':
get_template_part( 'content', 'portfolio-more' );
break;
}
}
?>
<?php } //END if ( !post_password_required() ) ?>
</div><!-- END .primary-content -->
</article>
<?php
endwhile;
endif;
get_footer();