网页常用分享代码大全(前端必备)

  发布时间:2013-07-25 17:42:07   作者:佚名   我要评论
分享在网页中的应用在今日已经相当的普及了,本文整理了一些常用的分享代码,可谓是应有尽有,大家不妨在制作的过程中参考下,或许对大家有所帮助
(福利推荐:【腾讯云】服务器最新限时优惠活动,云服务器1核2G仅99元/年、2核4G仅768元/3年,立即抢购>>>:9i0i.cn/qcloud

(福利推荐:你还在原价购买阿里云服务器?现在阿里云0.8折限时抢购活动来啦!4核8G企业云服务器仅2998元/3年,立即抢购>>>:9i0i.cn/aliyun


复制代码
代码如下:

1、新浪微博
<a href="http://v.t.sina.com.cn/share/share.php?url=&title='分享内容'" target="_blank">新浪微博</a> </p> <p>2、腾讯微博
<a href="http://v.t.qq.com/share/share.php?url=&title='分享内容'" target="_blank">腾讯微博</a> </p> <p>3、开心网
<a href="javascript:window.open('http://www.kaixin001.com/repaste/share.php?rtitle='+encodeURIComponent(document.title)+'&rurl='+encodeURIComponent(document.location.href)+'&rcontent=');void(0)">开心网</a>
或者用
<a href="http://www.kaixin001.com/repaste/share.php?rurl=&rcontent=http://www.baidu.com&rtitle=kaixin" target="_blank">开心网</a> </p> <p>4、豆瓣网
<a href="javascript:window.open('http://www.douban.com/recommend/?url='+encodeURIComponent(document.location.href)+'&title='+encodeURIComponent(document.title));void(0)">豆瓣</a> </p> <p>或者用
<a href="http://www.douban.com/recommend/?url=&title=douban" target="_blank">豆瓣</a> </p> <p>5、人人网
<a href="javascript:window.open('http://share.renren.com/share/buttonshare.do?link='+encodeURIComponent(document.location.href)+'&title='+encodeURIComponent(document.title));void(0)">人人网</a>
或者用
<a href="http://share.renren.com/share/buttonshare.do?link=" target="_blank">人人网</a> </p> <p>6、百度贴吧
<a href="http://tieba.baidu.com/f/commit/share/openShareApi?url=&title=hello&desc=&pic=" target="_blank">百度贴吧</a> </p> <p>7、QQ好友
<a href="http://connect.qq.com/widget/shareqq/index.html?title=qqhaoyou&url=&desc=还不错哦&pics=&site=优酷" target="_blank">QQ好友</a> </p> <p>8、QQ空间
<a href="http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=" target="_blank">QQ空间</a> </p> <p>9、腾讯朋友
<a href="http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?to=pengyou&url=" target="_blank">腾讯朋友</a> </p> <p>
10、百度收藏
<a href="javascript:window.open('http://cang.baidu.com/do/add?it='+encodeURIComponent(document.title.substring(0,76))+'&iu='+encodeURIComponent(location.href)+'&fr=ien#nw=1','scrollbars=no,width=600,height=450,left=75,top=20,status=no,resizable=yes'); void 0">百度搜藏</a> </p> <p>11、优酷空间
<a href="http://i.youku.com/u/share/?url=&content='分享内容'" target="_blank">优酷空间</a> </p> <p>12、搜狐微博
<a href="http://t.sohu.com/third/post.jsp?content=utf-8&url=&title=souhu" target="_blank">搜狐微博</a> </p> <p>13、MSN
<a href="http://profile.live.com/badge/?url=&Title=msn" target="_blank">MSN</a> </p> <p>14、猫扑
<a href="http://tt.mop.com/share/shareV.jsp?title=moptietie&pageUrl=" target="_blank">MOP贴贴</a> </p> <p>15、网易微博
<a href="http://t.163.com/article/user/checkLogin.do?link=" target="_blank">网易微博</a> </p> <p>16、QQ书签 </p> <p><a href="javascript:window.open('http://shuqian.qq.com/post?from=3&title='+encodeURIComponent(document.title)+'&uri='+encodeURIComponent(document.location.href)+'&jumpback=2&noui=1','favit','width=930,height=470,left=50,top=50,toolbar=no,menubar=no,location=no,scrollbars=yes,status=yes,resizable=yes');void(0)">QQ书签</a> </p> <p>17、GOOGLE书签:
<a href="javascript:window.open('http://www.google.com/bookmarks/mark?op=add&bkmk='+encodeURIComponent(document.location.href)+'&title='+encodeURIComponent(document.title));void(0)">Google</a> </p> <p>18、Twitter
<a href="javascript:window.open('http://twitter.com/home?status='+encodeURIComponent(document.location.href)+' '+encodeURIComponent(document.title));void(0)">Twitter</a> </p> <p>19、Facebook
<a class="fav_facebook" rel="nofollow" href="javascript:window.open('http://www.facebook.com/sharer.php?u='+encodeURIComponent(document.location.href)+'&t='+encodeURIComponent(document.title));void(0)">Facebook</a> </p> <p>20、Delicious书签: </p> <p><a href="javascript:window.open('http://del.icio.us/post?url='+encodeURIComponent(document.location.href)+'&title='+encodeURIComponent(document.title)+'&notes=');void(0)">Delicious</a>


由于现在很多分享平台都出来了,而且兼容性更好,一般多选择  百度分享等第三方分享平台。大家可以看下。

相关文章

  • web开发中的长度单位小结

    这篇文章主要介绍了web开发中的长度单位主要包括px,pt,em等,需要的朋友可以参考下
    2023-08-06
  • 网页前端开发的一些尺寸单位(px,rem单位)

    px单位是绝对单位,一般用于pc端网页开发,因为是绝对单位所以在移动端上的使用体验并不是很好,rem它是描述相对于当前根元素字体尺寸,是相对单位,它可以根据根元素的变换而
    2023-08-06
  • WEB前端优化必备js/css压缩工具YUI-compressor详解与集成用法

    压缩工具层次不穷,各有优点,选择适合的压缩工具为将来做项目开发使用是一件很重要的事情!!在这介绍YUI-compressor,需要的朋友可以参考下
    2023-06-21
  • html,css,javascript是怎样变成页面的

    浏览器是多进程的,有浏览器主进程,网络进程,渲染进程,插件进程等,在将html,css,javascript解析成一个页面的时候,就需要多个进程的分工合作
    2023-05-01
  • 常用Mime类型汇总

    本文为大家整理了常用的文件对应的MIME类型,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学习学习吧
    2022-04-25
  • postman中form-data、x-www-form-urlencoded、raw、binary的区别介绍

    这篇文章介绍了postman中form-data、x-www-form-urlencoded、raw、binary的区别,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学习学习吧
    2021-12-28
  • 网页中使用Unicode字符的介绍(&#,\u等)

    国际组织制定了可以容纳世界上所有文字和符号的字符编码方案,称为Unicode,是通用字符集Universal Character Set的缩写,用以满足跨语言、跨平台进行文本转换、处理的要求
    2021-11-27
  • 前端实现字符串GBK与GB2312的编解码(小结)

    这篇文章主要介绍了前端实现字符串GBK与GB2312的编解码(小结),小编觉得挺不错的,现在分享给大家,也给大家做个参考。一起跟随小编过来看看吧
    2020-12-02
  • 告别硬编码让你的前端表格自动计算的实例代码

    这篇文章主要介绍了告别硬编码让你的前端表格自动计算,本文通过实例代码给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友可以参考下
    2020-09-27
  • 浅析Table 和 div 的简介及用法

    这篇文章主要介绍了浅析Table 和 div 的简介及用法,本文通过实例代码给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友可以参考下
    2020-08-25

最新评论

?


http://www.vxiaotou.com