-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsingle.php
142 lines (89 loc) · 4.37 KB
/
single.php
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
<?php get_header(); ?>
<?php
$btnclass = mpt_load_mp_btn_color();
$iconclass = mpt_load_whiteicon_in_btn();
?>
<!-- Post -->
<div id="post-wrapper">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<?php
$headerbgcolor = esc_attr(get_post_meta( $post->ID, '_mpt_post_header_bg_color', true ));
$headertextcolor = esc_attr(get_post_meta( $post->ID, '_mpt_post_header_text_color', true ));
$contentbgcolor = esc_attr(get_post_meta( $post->ID, '_mpt_post_content_bg_color', true ));
$contenttextcolor = esc_attr(get_post_meta( $post->ID, '_mpt_post_content_text_color', true ));
?>
<div class="header-section"<?php echo ($headerbgcolor != '#' && !empty($headerbgcolor) ? ' style="background: '.$headerbgcolor.';"' : '') ?>>
<div class="outercontainer">
<div class="container">
<div class="clear padding20"></div>
<div class="row-fluid">
<div class="span2">
<div class="date-comment-box">
<?php
$year = get_the_time('Y');
$month = get_the_time('M');
$day = get_the_time('j');
?>
<div class="date">
<span class="month"><?php echo $month; ?></span>
<div class="clear"></div>
<span class="day"><?php echo $day; ?></span>
<div class="clear"></div>
<span class="year"><?php echo $year; ?></span>
</div>
<div class="comments"><a href="<?php comments_link(); ?>"><?php comments_number( 'No Comments' , '1 Comment' , '% Comments' ); ?></a></div>
</div>
</div>
<div class="span10">
<h1 class="page-header"><span<?php echo ($headertextcolor != '#' && !empty($headertextcolor) ? ' style="color: '.$headertextcolor.'; border-bottom-color: '.$headertextcolor.'; border-top-color: '.$headertextcolor.';"' : '') ?>><?php the_title(); ?></span></h1>
<div class="post-meta">
<p><?php _e( 'Posted By ', 'flexmarket' ); ?><?php the_author(); ?> <?php _e( 'In', 'flexmarket' ); ?> <span class="label label-tag"><?php the_category('</span> <span class="label label-tag">'); ?></span> <?php the_tags( __( 'Tagged with ', 'flexmarket' ).'<span class="label label-tag">' , '</span> <span class="label label-tag">' , '</span>'); ?> </p>
</div>
</div>
<div class="clear padding20"></div>
</div>
</div><!-- / container -->
</div><!-- / outercontainer -->
</div><!-- / header-section -->
<div class="content-section"<?php echo ($contentbgcolor != '#' && !empty($contentbgcolor) ? ' style="background: '.$contentbgcolor.';"' : '') ?>>
<div class="outercontainer">
<div class="clear padding30"></div>
<div class="container">
<div class="row-fluid">
<div class="span8">
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?><?php echo ($contenttextcolor != '#' && !empty($contenttextcolor) ? ' style="color: '.$contenttextcolor.';"' : '') ?>>
<?php mpt_load_top_code(); ?>
<?php $temp = get_post_meta( $post->ID, '_mpt_post_select_temp', true ); ?>
<?php if (has_post_thumbnail( $post->ID ) || $temp == 'video' ) : ?>
<?php
$id = get_the_ID();
if ($temp == 'image-carousel') {
mpt_load_image_carousel( $id , 'tb-860' , true );
} else if ($temp == 'video') {
mpt_load_video_post( $id , '300');
} else {
mpt_load_featured_image( $id , 'tb-860' , true , $btnclass , $iconclass);
}
?>
<?php endif; ?>
<div class="clear padding20"></div>
<?php the_content(); ?>
<div class="clear padding20"></div>
<?php edit_post_link('Edit this entry.', '<p>', '</p>'); ?>
<div class="clear padding30"></div>
<?php comments_template(); ?>
</div>
<?php endwhile; endif; ?>
<?php mpt_load_bottom_code(); ?>
</div><!-- / span8 -->
<div id="sidebar" class="span4">
<?php get_sidebar(); ?>
</div>
</div><!-- / row-fluid -->
<div class="padding20"></div>
</div><!-- / container -->
</div><!-- / outercontainer -->
</div><!-- / content-section -->
</div><!-- / page-wrapper -->
<?php get_template_part('footer', 'widget'); ?>
<?php get_footer(); ?>