Skip to content
This repository has been archived by the owner. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
add linkedin share link
  • Loading branch information
jjc16105 committed Aug 24, 2016
1 parent c166896 commit 85ea24f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions content-single.php
@@ -1,6 +1,7 @@
<?php
// This is used when viewing a single post.
?>

<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<header class="entry-header">
<?php /* if ( has_post_thumbnail() ) {
Expand Down Expand Up @@ -32,7 +33,7 @@
if(empty($facebookshareline)) $facebookshareline = get_the_title();
$linkedinshareline = get_post_meta( $post->ID, 'linkedinshareline', true);
if(empty($linkedinshareline)) $linkedinshareline = get_the_title();

?>
<div class="shareline-twitter">
<a href="#" onclick="window.open('https://twitter.com/intent/tweet?text=<?php echo urlencode(preg_replace("/&#?[a-z0-9]+;/i","",html_entity_decode($twittershareline)));?>&url=<?php echo urlencode(get_permalink()); ?>&via=UConnBusiness', 'Twitter', 'width=500,height=500');"><span class="social social-twitter"></span><span><?php echo $twittershareline; ?></span></a>
Expand All @@ -42,8 +43,9 @@
<a href="http://www.facebook.com/sharer/sharer.php?u=<?php the_permalink(); ?>"><span class="social social-facebook"></span><span><?php echo $facebookshareline; ?></span></a>
</div>


<div class="shareline-linkedin">
<a href="https://www.linkedin.com/shareArticle?url=<?php the_permalink(); ?>"><span class="social social-linkedin"></span><span><?php echo $linkedinshareline; ?></span></a>
<a href="https://www.linkedin.com/shareArticle?mini=true&url=<?php echo urlencode(the_permalink()); ?>&title=<?php echo urlencode(the_title()); ?>&summary=<?php echo urlencode(get_the_excerpt()); ?>&source=UConn-Aurora"><span class="social social-linkedin"></span><span><?php echo $linkedinshareline; ?></span></a>
</div>
</div>

Expand Down Expand Up @@ -108,6 +110,8 @@

</div>

<meta prefix="og: http://ogp.me/ns#" property="og:image" content="http://i.cdn.turner.com/cnn/.e/img/3.0/global/misc/apple-touch-icon.png" />

<div id="social-buttons">
<div class="row">
<div class="col-sm-2">Share on:</div>
Expand Down

0 comments on commit 85ea24f

Please sign in to comment.