<?php
$permalink = urlencode(get_permalink($post->ID));
$title = urlencode($post->post_title);
$title = str_replace('+','%20',$title);
?>
<li id="xianguo">
<a href="http://www.xianguo.com/service/submitdigg/?link=<?php echo $permalink; ?>&
title=<?php echo $title; ?>" target="_blank" rel="nofollow">分享到鲜果</a>
</li>
<li id="douban">
<a href="http://www.douban.com/recommend/?url=<?php echo $permalink; ?>&title=<?php echo $title; ?>&sel=&v=1" target="_blank" rel="nofollow">分享到豆瓣</a>
</li>
<li id="zuosa">
<a href="javascript:u=location.href;t=document.title;t=t.substr(0,76);c=%22%22+(window.getSelection?window.getSelection():document.getSelection?document.getSelection():document.selection.createRange().text);c=c.substr(0,180);location=%22http://zuosa.com/collect/Collect.aspx?t=%22+encodeURIComponent(t)+%22&u=%22+encodeURIComponent(u);void%200">分享到做啥</a>
</li>
<li id="xiaonei">
<a href="http://share.xiaonei.com/share/buttonshare.do?link=<?php the_permalink() ?>&title=<?php the_title(); ?>"target="_blank" rel="nofollow" >分享到人人网</a>
</li>
<li id="kaixin001">
<a href="http://www.kaixin001.com/repaste/share.php?url=<?php the_permalink() ?>&title=<?php the_title(); ?>" title="分享到开心网" target="_blank" rel="nofollow">分享到开心网</a>
</li>
<li id="sina"><a href="http://v.t.sina.com.cn/share/share.php?url=<?php the_permalink() ?>&title=<?php the_title(); ?>"target="_blank" rel="nofollow" " title="分享到新浪微博" target="_blank" rel="nofollow">分享到新浪微博</a></li>
/************************************************
* bookmark *
************************************************/
#share {
background:none repeat scroll 0 0 #FFF6EE;
-moz-border-radius:5px 5px 5px 5px;
-webkit-border-radius: 5px;
background:none repeat scroll 0 0 #FFF6EE;
border:1px solid #FFF6CC;
width:602px;
float:left;
}
#share li {
background:url("images/share.gif") no-repeat scroll 0 0 transparent;
float:left;
margin:6px 0 0 5px;
padding:4px 0 4px 20px;
list-style-type:none;
}
#share li#fanfou {
background-position:0 -44px;
}
#share li#facebook {
background-position:0 -22px;
}
#share li#friendfeed {
background-position:0 -66px;
}
#share li#douban {
background-position:0 -110px;
}
#share li#xiaonei {
background-position:0 -87px;
}
#share li#zuosa {
background-position:0 -130px;
}
#share li#myspace {
background-position:0 -153px;
}
#share li#kaixin001 {
background-position:0 -176px;
}
#share li#xianguo {
background-position:0 -199px;
}
#share li#sina {
background-position:0 -220px;
}
<p id="share">
<ul><?php include(TEMPLATEPATH."/bookmark.php");?></ul>
</p>
以上就是安达网络工作室关于《手工添加WordPress文章分享按钮(无插件)实现步骤》的一些看法。更多内容请查看本栏目更多内容!
WordPress 上获取文章最重要的就是循环(Loop),现实上循环就是去数据库查问到相应的文章,而后临时贮存到...
很多冤家刚建设博客的时分都是采纳国际优秀的博客零碎:Z-BLOG,用一段工夫当时很多人都想转移到wordpress,...
首先,什么是以后博客?和独自站点不同的是,Multisite会产生多个博客,称之为blog,即子站点(包括主站点)...
WordPress 自身以及主题和插件通常需求加载一些 JavaScript 来完成某些非凡性能。为了最大限制地保障兼容性...
WordPress的文章、评论等很少数据都是寄存在数据库的,所以搭建wordpress网站的工夫,网站的空间不需求多大...
导航菜单 导航菜单早已 "深化民意", 在博客上的使用日益重要且多样. 从本文开端, 我将展开几个对于 WordPre...