Add Slick Social Media Sharing Icons to Thesis Theme

You can see in my website, i have a very flexible social media sharing icon and it work fine with thesis theme. I was using the share code from Art of Blog, he’s one of the most well know blogger i ever know.

If you want to have a social media sharing icon like me, you can follow Art of Blog blog and follow his tutorial. But with some thesis blog, you can have a problem with:

Parse error: syntax error, unexpected '< ' in

Actually, it’s not a bug of code, it just about the way of your coding  in custom_functions.php.

You can fixed this problem by add my code in custom_functions.php

// Social Media
function social_icons(){
if(is_single()){
$twitter=’saigonseo’;
global $post; ?>
<div>
<strong>Spread it!</strong>
<div>
<a><img src=”http://digg.com/img/diggThisCompact.png” height=”18″ width=”120″ alt=”DiggThis” /></a>
</div>
<div>
<script type=”text/javascript”>    tweetmeme_source = ‘<?php echo $twitter; ?>’;    tweetmeme_style = ‘compact’;    </script>
<script type=”text/javascript” src=”http://tweetmeme.com/i/scripts/button.js”></script>
</div>
<div>
<a name=”fb_share” type=”button_count” href=”http://www.facebook.com/sharer.php”>Share</a>
</div>
<div>
<a href=”http://www.stumbleupon.com/submit?url=<?php the_permalink(); ?>&title=<?php the_title(); ?>” id=”stumbleupon” target=”_blank”><img src=”http://cdn.stumble-upon.com/images/badgeStumble.png” alt=”submit to Stumble Upon”/>
</a>
</div>
<div>
<a href=”mailto:?subject=Sharing: <?php the_title(); ?>&body=I wanted to share this with you. Thought you might enjoy it:%0A%0A<?php the_permalink(); ?>” title=”Email This” target=”_blank”>Email This</a>
</div>
</div>
<div></div>
<?php
function digg_footer(){
echo ‘<script src=”http://digg.com/tools/diggthis.js” type=”text/javascript”></script>’;
echo ‘<script src=”http://static.ak.fbcdn.net/connect.php/js/FB.Share” type=”text/javascript”></script>’;
}
add_action(‘wp_footer’,'digg_footer’);
}
}
add_action(‘thesis_hook_before_post’,'social_icons’); ?>

Thanks Nick Reese for cool code sharing !

Leave a Comment

Previous post:

Next post: