function shareys(type, url, title, img, content)
{
switch (type) {
case "sina":
url = "http://service.weibo.com/share/share.php?title=" + encodeURIComponent(content + '「' + title + '」' + ' 点这里' + url) + '&pic=' + img;
window.open(url);
break;
case "tqq":
url = "http://v.t.qq.com/share/share.php?url=" + encodeURIComponent(url) + '&title=' + encodeURIComponent(title) + '&pic=' + img;
window.open(url);
break;
case "qzone":
url = 'http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=' + encodeURIComponent(url + '#-39yst-1-001') + '&title=' + encodeURIComponent(title) + '&site=&pics=' + encodeURIComponent(img) + '&desc=' + encodeURIComponent(content) +'&summary=' + encodeURIComponent(content);
window.open(url);
break;
case "ren":
url = 'http://widget.renren.com/dialog/share?resourceUrl=' + encodeURIComponent(url) + '&srcUrl=' + img + '&title=' + encodeURIComponent(title);
+'&description=' + content;
window.open(url);
break;
default:
break;
}
}
<script type="text/javascript">
function postsShare(pType)
{
var pTitle = "{:$seo_title:}";
var pImage = "";
var pContent = "{:$seo_desc:}";
var pUrl = window.location.href;
shareys(pType, pUrl, pTitle, "", pContent);
}
</script>