added share button on sigle post
This commit is contained in:
parent
af00b584a0
commit
0d260f1e1d
|
@ -17,6 +17,10 @@
|
|||
margin-top: -10px;
|
||||
}
|
||||
}
|
||||
img {
|
||||
height: 24px;
|
||||
padding-left: 1rem;
|
||||
}
|
||||
}
|
||||
img{
|
||||
max-width: 100%;
|
||||
|
|
|
@ -1,7 +1,25 @@
|
|||
<article role="article" id="post_<?php the_ID()?>" <?php post_class()?>>
|
||||
<header class="mb-4">
|
||||
<div class="header-meta text-muted mb-5">
|
||||
<div class="header-meta text-muted mb-5 d-flex">
|
||||
<?php tainacan_post_date(); ?> <?php printf(__('by %s', 'tainacan-theme'), get_the_author_posts_link()); ?>
|
||||
<div class="btn-group ml-auto" role="group">
|
||||
<?php if ( true == get_theme_mod( 'facebook_share', true ) ) : ?>
|
||||
<a href="http://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>" class="" target="_blank">
|
||||
<img src="<?=get_template_directory_uri().'/assets/images/facebook-circle.png'; ?>" alt="">
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( true == get_theme_mod( 'twitter_share', true ) ) : ?>
|
||||
<?php $via = !empty(get_option( 'twitter_user')) ? '&via=' . get_option( 'twitter_user') : ''; ?>
|
||||
<a href="http://twitter.com/share?url=<?php the_permalink(); ?>&text=<?php the_title_attribute(); ?><?php echo $via; ?>" target="_blank" class="">
|
||||
<img src="<?=get_template_directory_uri().'/assets/images/twitter-circle.png'; ?>" alt="">
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( true == get_theme_mod( 'google_share', true ) ) : ?>
|
||||
<a href="https://plus.google.com/share?url=<?php the_permalink(); ?>" target="_blank" class="">
|
||||
<img src="<?=get_template_directory_uri().'/assets/images/google-plus-circle.png'; ?>" alt="">
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php the_post_thumbnail(); ?>
|
||||
</header>
|
||||
|
|
Loading…
Reference in New Issue