->
效果见博客右下角的tweet me!链接,方便访问者将博客发送到twitter。发送后的博客链接为经过yourls处理过的短链接。
打开并编辑Yourls: wordpress to twitter插件,增加函数,代码如下:
function myUrlShort()
{
global $id;
$short = wp_ozh_yourls_geturl( $id );
if ($short) echo $short;
}
在要放置tweet me!链接的地方放置如下代码:
<a target=”_blank” title=”Share this article with your Twitter followers” href=”http://twitter.com/home?status=Reading%3A+<?php the_title(); ?> – <?php $turl = myUrlShort();?> (via @LiJie)” rel=”nofollow”>Tweet me!</a>
这样就实现了tweet me的功能。点击链接后的效果如下:

No Comments Now!
Be the first to comment on this entry.