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>

最新文章

  1. [转]hql 语法与详细解释
  2. oracle实现split函数功能
  3. Vue.js – 基于 MVVM 实现交互式的 Web 界面
  4. 让所有的浏览器都支持html5
  5. oracle创建用户、表空间、授权
  6. 12.162s 1805.867s
  7. Optimizing shaper — hashing filters (HTB)
  8. 华为OJ平台——字符串通配符
  9. Asp.net Json 解析 与 直接用ip访问返回josn
  10. Tesla为什么要公开专利
  11. SourceTree + Bitbucket - 轻松云端作业
  12. poj3617Best Cow Line
  13. [Android]Android焦点流程代码分析
  14. JDK动态代理[1]----代理模式实现方式的概要介绍
  15. 如何处理导出的csv无法查看身份证后三位的情况?
  16. 10. Firewalls (防火墙 2个)
  17. PAT甲级题解-1047. Student List for Course (25)-排序
  18. delphi制作登陆窗体
  19. 规避javascript多人开发函数重名问题
  20. 解决servlet-api包冲突问题(maven)

热门文章

  1. fpga之显示字符串
  2. Pass和ClassPath变量配置
  3. Python学习笔记——基础篇【第六周】——json &amp; pickle &amp; shelve &amp; xml处理模块
  4. Lua math库
  5. out和ref之间的区别
  6. HTML中判断手机是否安装某APP,跳转或下载该应用
  7. java上传并下载以及解压zip文件有时会报文件被损坏错误分析以及解决
  8. Spring mail 邮件发送的简单实现
  9. Windows漏洞利用与防护(2015.8)
  10. es6--(二)变量的解构赋值