-
Notifications
You must be signed in to change notification settings - Fork 0
/
single.php
71 lines (64 loc) · 2.29 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
<?php get_header(); ?>
<?php if ( !is_front_page() ) : ?>
<div class="breadcrumb wrapper">
<p><?php if(function_exists('bcn_display')) { bcn_display(); } ?></p>
</div>
<?php endif; ?>
<div class="wrapper">
<div class="content">
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
<div class="row header">
<div class="col-md-4 col pull-right">
<div class="content header-content header-content-fixed <?= get_field('quote_box_color') ?>">
<?php dynamic_sidebar( 'single-blog-widget' ); ?>
</div>
</div>
<div class="col-md-8 col">
<?= post_image(get_the_id()) ?>
</div>
</div>
<?php
$start_date = get_the_date('m/d');
$post_categories = wp_get_post_categories(get_the_id());
foreach( $post_categories as $cat ) {
$cat = get_category( $cat );
$cats[] = array( 'name' => $cat->name, 'slug' => $cat->slug );
}
$tags_html = build_tags_html( $cats, $start_date );
?>
<div class="row blog">
<div class="col-md-8 teaser blog-post">
<div class="grid-info">
<?php echo $tags_html; ?>
<div>
<h1><a href="<?php echo get_the_permalink(); ?>"><?php echo get_the_title(); ?></a></h1>
<?php the_content(); ?>
<div class="grid-aside-content">
<ul>
<li>
<a class="fb-share" href="https://www.facebook.com/sharer/sharer.php?u=<?php echo urlencode(get_the_permalink()) ?>" target="_blank">
<i class="fa fa-facebook"></i>Share on Facebook
</a>
</li>
<li>
<a class="fb-share" href="http://twitter.com/share?text=<?php echo urlencode( get_the_title() ); ?>&url=<?php echo urlencode(get_the_permalink()) ?>" target="_blank">
<i class="fa fa-twitter"></i>Share on Twitter
</a>
</li>
<li>
<a href="mailto:?subject=<?php echo get_the_title(); ?>&body=<?php echo urlencode( get_the_permalink() ); ?>">
<i class="fa fa-envelope-o"></i>Forward to Friends
</a>
</li>
</ul>
</div>
<a href="<?php echo get_site_url(); ?>/news/blog/" title="Blog Homepage" class="btn-bpca">Back to Blog Homepage</a>
</div>
</div>
</div>
</div>
<?php endwhile; endif; ?>
</div>
<div class="clear"></div>
</div>
<?php get_footer(); ?>