
In some website links available at this time “Share on Facebook”. Links that are popular this allows the user to display any posts snippets, news, article or a blog / site at Facebook account.
How do include this feature to your website? Here the trick:
1. Put the code / script in this file single.php, post.php, or other files that show the function of any posts / posting on the blog.
<script type=”"text/javascript”"> function fbs_click ()
(
u = location.href;
t = document.title;
window.open ( ‘http://www.facebook.com/sharer.php?u =’ + encodeURIComponent (u) + ‘& t =’ + encodeURIComponent (t), ‘sharer’, ‘toolbar = 0, status = 0 , width = 626, height = 436 ‘); return false;
)
</ script>
<a href=”http://www.facebook.com/share.php?u=put_your_url_here” onclick=”return fbs_click()” target=”_blank”>
<img src=” share-on-facebook.jpg” alt=\”Share On Facebook\” align=”left”/>
</ a>
<? php echo ”
<a href = \ “http://www.addthis.com/bookmark.php?pub=Website_Name&url =”. get_permalink ().”& title = “. get_the_title ($ id).” \ “title = \” folder and Share “target = \” _blank \ “> <img src = \” http://s7.addthis.com/button1-share.gif \ “width =” 125 “height = \” 16 \ “border = \ “0 \” alt = “Bookmark and Share \” align = \ “right \” /> </ a> “?>
2. Watch on “put_your_url_here“. Replace the text with your an URL address.and after that, Replace “Website_Name” with the name of your site.
3. So you do not need to type the link on each web page, replace any posts “put_your_url_here” with functions that can be men-generate or return the URL of each post. For example, if you’re using a WordPress blog, replace with <? Php the_permalink ();?> .
Or the simple way is, You install addon if you using wordpress.Like “I love Bookmarking” Here or other bookmarking plugins.










