-
Notifications
You must be signed in to change notification settings - Fork 8
/
content.php
106 lines (86 loc) · 4.01 KB
/
content.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
<?php global $dt_blog_sidebar_position,$sd_sidebar_class,$post;?>
<article <?php post_class(); ?>>
<?php
if (((function_exists('is_buddypress') && !is_buddypress()) || !function_exists('is_buddypress')) && !get_post_meta($post->ID,'sd_remove_head',true)) { ?>
<header>
<div class="featured-area">
<div class="featured-img" <?php
if (has_post_thumbnail()) { // check if the post has a Post Thumbnail assigned to it.
$full_image_url = wp_get_attachment_image_src(get_post_thumbnail_id(), 'full');
}else{
$full_image_url[0] = SD_DEFAULT_FEATURED_IMAGE;
}
?> style="background-image: url('<?php echo esc_url($full_image_url[0]); ?>');" <?php
?>>
</div>
<div class="header-wrap">
<?php
do_action('sd_feature_area');
?>
</div>
</div>
</header> <?php
} ?>
<div class="container" id="home-scroll">
<?php
if($dt_blog_sidebar_position=='left'){?>
<div class="sd-sidebar sd-sidebar-left">
<div class="sidebar blog-sidebar page-sidebar">
<?php if(is_page()){get_sidebar('pages');}else{get_sidebar();}?>
</div>
</div>
<?php }?>
<div class="entry-content entry-summary <?php echo $sd_sidebar_class;?>">
<?php
global $more;
$more = 0;
if (is_singular() || ( function_exists('is_bbpress') && is_bbpress() )) {
the_content();
} else {
directory_theme_post_thumbnail();
the_excerpt();
}
?>
<?php
wp_link_pages(array(
'before' => '<div class="page-links"><span class="page-links-title">' . __('Pages:', 'supreme-directory') . '</span>',
'after' => '</div>',
'link_before' => '<span>',
'link_after' => '</span>',
));
?>
<footer class="entry-footer">
<?php directory_theme_entry_meta(); ?>
<?php edit_post_link(__('Edit', 'supreme-directory'), '<span class="edit-link">', '</span>'); ?>
<?php
global $post;
if(is_single() && isset($post->post_type) && $post->post_type='post'){
// Previous/next post navigation.
the_post_navigation(array(
'next_text' => '<span class="meta-nav" aria-hidden="true">' . __('Next', 'supreme-directory') . '</span> ' .
'<span class="screen-reader-text">' . __('Next post:', 'supreme-directory') . '</span> ' .
'<span class="post-title">%title</span>',
'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __('Previous', 'supreme-directory') . '</span> ' .
'<span class="screen-reader-text">' . __('Previous post:', 'supreme-directory') . '</span> ' .
'<span class="post-title">%title</span>',
));
}
// If comments are open or we have at least one comment, load up the comment template.
if (comments_open() || get_comments_number()) : ?>
<div class="comments-container">
<?php comments_template(); ?>
</div>
<?php endif;
?>
</footer>
</div>
<?php
if($dt_blog_sidebar_position=='right'){?>
<div class="sd-sidebar sd-sidebar-right">
<div class="sidebar blog-sidebar page-sidebar">
<?php if(is_page()){get_sidebar('pages');}else{get_sidebar();} ?>
</div>
</div>
<?php }?>
</div>
</article>