码迷,mamicode.com
首页 > Web开发 > 详细

嵌套 QQ、微博 通讯工具到HTML中

时间:2016-09-10 17:48:55      阅读:248      评论:0      收藏:0      [点我收藏+]

标签:

自己QQ、微博的实例:

技术分享
  1 <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" Culture="zh-CN" %>
  2 
  3 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  4 
  5 <html  xmlns="http://www.w3.org/1999/xhtml" xmlns:wb="http://open.weibo.com/wb" >
  6 <head runat="server">
  7     <script src="http://tjs.sjs.sinajs.cn/open/api/js/wb.js" type="text/javascript" charset="utf-8"></script>
  8     <style type="text/css">
  9         .style1
 10         {
 11             height: 974px;
 12             width: 1378px;
 13         }
 14         .style2
 15         {
 16             width: 1439px;
 17             left: 22px;
 18             bottom: 22px;
 19             height: 31px;
 20         }
 21         .style3
 22         {
 23             width: 1404px;
 24             height: 27px;
 25         }
 26         .style4
 27         {
 28             width: 1452px;
 29             height: 32px;
 30         }
 31         .style5
 32         {
 33             height: 29px;
 34             width: 1374px;
 35         }
 36         .style6
 37         {
 38             height: 31px;
 39         }
 40         .style7
 41         {
 42             width: 1439px;
 43         }
 44         .style8
 45         {
 46             height: 107px;
 47         }
 48         .style9
 49         {
 50             width: 666px;
 51         }
 52     </style>
 53 </head>
 54 <meta property="og:type" content="webpage" />
 55 <body>
 56     <form id="form1" runat="server">
 57     <div align="center" class="style1" 
 58         style="padding:250px; background-color: #00FFFF">
 59         <div align="right" class="style2" style="clip: rect(auto, auto, auto, auto);">
 60             <div class="style9">
 61             </div>
 62              <wb:share-button addition="number" type="button" ralateUid="3147308540" default_text="用力戳我分享" pic="http%3A%2F%2Fimg3.imgtn.bdimg.com%2Fit%2Fu%3D3152527272%2C3368143393%26fm%3D21%26gp%3D0.jpg" language="zh_cn"></wb:share-button>
 63         </div>
 64         <div align="right" class="style5">
 65              <wb:follow-button uid="3147308540" type="red_1" width="67" height="24" ></wb:follow-button>
 66         </div>
 67         <div align="left" class="style6">
 68              <script type="text/javascript">            document.write(<iframe width="260" height="239" frameborder="0" scrolling="no" src="http://widget.weibo.com/relationship/bulkfollow.php?language=zh_cn&uids=3147308540&wide=1&color=C2D9F2,FFFFFF,0082CB,666666&showtitle=1&showinfo=1&sense=0&verified=1&count=1&refer= + encodeURIComponent(location.href) + &dpc=1"></iframe>)</script>
 69         </div></br>
 70         <div align="right" class="style3">
 71         <script type="text/javascript">
 72             (function () {
 73                 var p = {
 74                     url: location.href, /*获取URL,可加上来自分享到QQ标识,方便统计*/
 75                     desc: ‘‘, /*分享理由(风格应模拟用户对话),支持多分享语随机展现(使用|分隔)*/
 76                     title: ‘‘, /*分享标题(可选)*/
 77                     summary: ‘‘, /*分享摘要(可选)*/
 78                     pics: ‘‘, /*分享图片(可选)*/
 79                     flash: ‘‘, /*视频地址(可选)*/
 80                     site: ‘‘, /*分享来源(可选) 如:QQ分享*/
 81                     style: 101,
 82                     width: 96,
 83                     height: 24
 84                 };
 85                 var s = [];
 86                 for (var i in p) {
 87                     s.push(i + = + encodeURIComponent(p[i] || ‘‘));
 88                 }
 89                 document.write([<a class="qcShareQQDiv" href="http://connect.qq.com/widget/shareqq/index.html?, s.join(&), " target="_blank">分享到QQ</a>].join(‘‘));
 90             })();
 91 </script>
 92 <script src="http://connect.qq.com/widget/loader/loader.js" widget="shareqq" charset="utf-8"></script>
 93         </div>
 94         <div align="right" class="style4" id="一份">
 95          <script type="text/javascript">
 96              (function () {
 97                  var p = {
 98                      url: location.href,
 99                      showcount: 1, /*是否显示分享总数,显示:‘1‘,不显示:‘0‘ */
100                      desc: ‘‘, /*默认分享理由(可选)*/
101                      summary: ‘‘, /*分享摘要(可选)*/
102                      title: ‘‘, /*分享标题(可选)*/
103                      site: ‘‘, /*分享来源 如:腾讯网(可选)*/
104                      pics: ‘‘, /*分享图片的路径(可选)*/
105                      style: 102,
106                      width: 145,
107                      height: 30
108                  };
109                  var s = [];
110                  for (var i in p) {
111                      s.push(i + = + encodeURIComponent(p[i] || ‘‘));
112                  }
113                  document.write([<a version="1.0" class="qzOpenerDiv" href="http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?, s.join(&), " target="_blank">分享</a>].join(‘‘));
114              })();
115         </script>
116 <script src="http://qzonestyle.gtimg.cn/qzone/app/qzlike/qzopensl.js#jsdate=20111201" charset="utf-8"></script>
117         </div>
118         <div align="right" class="style7">
119         <a version="1.0" class="qzOpenerDiv" href="http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_likeurl" target="_blank">赞</a><script  src="http://qzonestyle.gtimg.cn/qzone/app/qzlike/qzopensl.js#jsdate=20111107&style=2&showcount=1&width=130&height=30" charset="utf-8" defer="defer" ></script>
120         </div>
121         <div align="center" class="style8">
122         <a href="http://user.qzone.qq.com/1432581545" target="_blank">
123             <img src="http://r.qzone.qq.com/cgi-bin/cgi_get_user_pic?openid=000000000000000000000000172D1D21&pic=1.jpg&key=a261c26d7df8cf576c16e4b0d7b4421c" 
124                 align="right"></a>
125         </div>
126     </div>
127     </form>
128 </body>
129 </html>
View Code

 

嵌套 QQ、微博 通讯工具到HTML中

标签:

原文地址:http://www.cnblogs.com/lovelei/p/5859698.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!