设为首页收藏本站

LinuxTone | 运维专家网论坛 - 最棒的Linux运维与开源架构技术交流社区!

 找回密码
 注册

用新浪微博连接

一步搞定

QQ登录

只需一步,快速开始

查看: 736|回复: 3

js 懂吗?兄弟们,帮我看看 [复制链接]

Rank: 6Rank: 6

签到
80
注册时间
2009-5-7
最后登录
2012-1-17
在线时间
135 小时
阅读权限
70
积分
1819
帖子
96
主题
14
精华
0
UID
2926
发表于 2010-9-3 14:48:23 |显示全部楼层
  1.    <script>
  2.             function G(str){
  3.                  return document.getElementById(str);
  4.          };
  5.   
  6.          String.prototype.trim = function(){
  7.                  var trimer = new RegExp("(^[\\s\\t\\xa0\\u3000]+)|([\\u3000\\xa0\\s\\t]+\x24)", "g");
  8.                  return this.replace(trimer, "");
  9.          }
  10.                  
  11.         function clickBox(){
  12.                  var ibox = G('ibox');
  13.                  ibox.style.display = "block";
  14.                  G('icontent').focus();
  15.          };
  16.   
  17.         function closeBox(){
  18.                  var ibox = G('ibox');
  19.                  ibox.style.display = "none";
  20.          };
  21.                  
  22.         function submit(){
  23.                  var text = G('icontent').value.trim().substr(0, 280);
  24.           
  25.                  if(text == ""){
  26.                          G('err').innerHTML = "请输入内容";
  27.                          return false;
  28.                  }
  29.           
  30.                  log("http://static.mp3.baidu.com/wd/feedback.gif?word=" + encodeURIComponent(text) + "&query=" + encodeURIComponent("閬楀け鐨勭編濂� $张韶涵"));
  31.                  G('icontent').value = "";
  32.                  G('err').innerHTML = "";
  33.           
  34.                  closeBox();
  35.          };

  36.          (function(){
  37.                     var word = encodeURIComponent("遗失的美好??张韶涵");
  38.                     var ecom = ['rAd', 'gg189', 'adv'];
  39.                     for (var k in ecom) {
  40.                         var h = G("textarea_" + ecom[k]).value;
  41.                         G(ecom[k]).innerHTML = /src="([^"]+\.htm)"/im.test(h) ? h.replace(/src="([^"]*\.htm)"/im, 'src="$1?word=' + word + '"') : h.replace(/src="([^"]+)"/im, 'src="$1&word=' + word + '"');
  42.                     }
  43.                 })();

  44.                 var song_1283495866;
  45.                 var sertim = 1283495866, statim = 1;
  46.                 var subcnt = 0;

  47.                 function G(str){
  48.                     return document.getElementById(str);
  49.                 }

  50.                 function log(url){
  51.                     var n = "log_" + (new Date()).getTime();
  52.                     var c = window[n] = new Image();
  53.                     c.src = url;
  54.                     c = null;
  55.                 }

  56.                 function sd(ev, pos, el){
  57.                     var ev = ev || window.event;
  58.                     var kc = (ev.button == 2) ? 1 : 0;
  59.                     var url = el ? el.href : song_1283495866;
  60.                     log("http://imgs.zhangmen.baidu.com/wd/sg-url.jpg?url=" + url + "&kc=" + kc + "&pos=" + pos + "&title=" + encodeURIComponent("遗失的美好$张韶涵") + "&is_recmd=" + is_recmd + "&r=" + Math.random());
  61.                 }

  62.                 function decode(url){
  63.                     var len = url.length;
  64.                     var decurl = "";
  65.                     var asc_arr1 = [], asc_arr2 = [];

  66.                     var key = sertim % 26;
  67.                     key = key ? key : 1;

  68.                     function init(head, bottom, middle){
  69.                         for (var i = head; i <= bottom; i++) {
  70.                             asc_arr1[i] = i + middle;
  71.                             asc_arr2[i + middle] = i;
  72.                         }
  73.                     }

  74.                     init(0, 9, 48);
  75.                     init(10, 35, 55);
  76.                     init(36, 61, 61);

  77.                     for (var i = 0; i < len; i++) {
  78.                         var word = url.charAt(i);

  79.                         if (/[A-Za-z0-9]/.test(word)) {
  80.                             var pos = asc_arr2[url.charCodeAt(i)] - key;
  81.                             if (pos < 0)
  82.                                 pos += 62;
  83.                             word = String.fromCharCode(asc_arr1[pos]);
  84.                         }
  85.                         decurl += word;
  86.                     }

  87.                     return decurl;
  88.                 }

  89.                 -function(){
  90.                     var encurl = "x995://y2w.Dyq43uy.s42/5x4948/IGGMHGGN/IIHG/47ywOGHPK.25J" || "x995://y2w.Dyq43uy.s42/5x4948/IGGMHGGN/IIHG/47ywOGHPK.25J", newurl = "";
  91.                     var urln_obj = G("urln"), urla_obj = G("urla");

  92.                     newurl = decode(encurl);

  93.                     urln_obj.href = urla_obj.href = song_1283495866 = newurl;

  94.                     if (/wma\.ddeee\.com\.cn/i.test(newurl)) {
  95.                         G("dl").style.display = "inline";
  96.                         log('http://imgs.zhangmen.baidu.com/wd/any.gif?wd=下载页导流展现&r=' + Math.random());
  97.                     }

  98.                     urla_obj.innerHTML = decode("x995://y2w.Dyq43uy.s42/.../IIHG/47ywOGHPK.25J" || "x995://y2w.Dyq43uy.s42/.../47ywOGHPK.25J");

  99.                     if (!statim || sertim - statim < 3600) {
  100.                         log("/wd/mp3-sg-decode.jpg?url=" + newurl + "&r=" + Math.random());
  101.                     }
  102.                 }();

  103.                 -function(){
  104.                     var subulrs = ["x995://s439u39.HILJG.s42/s28tq9q/rq9sx2A8ys/IGGOGJIK/YG5zUeXp.25J", "x995://5MI.LM.s42/5x494IBytu4/A5cA8ys/HI/KL/EDEDEy3w_KPtONMOrvGHuNNOP.25J", "x995://y3t43u8yq3.s7y.s3/2284A7su/qAty4/IGGL/GI/GO/Ey8xytu2uyxq4.72", "x995://3uC8.13t.s42.s3/8y9uH/IGHGGNGL/GGLGLMsGGGGHGtPruIPqKH.25J"];
  105.                     var subulrs_s = ["x995://s439u39.HILJG.s42/...GJIK/YG5zUeXp.25J", "x995://5MI.LM.s42/...y3w_KPtONMOrvGHuNNOP.25J", "x995://y3t43u8yq3.s7y.s3/.../Ey8xytu2uyxq4.72", "x995://3uC8.13t.s42.s3/...GGGGHGtPruIPqKH.25J"];
  106.                     var str = "";

  107.                     for (var k in subulrs) {
  108.                         if (subulrs[k]) {
  109.                             subcnt++;
  110.                             if (subcnt > 1)
  111.                                 str += "<br>";
  112.                             str += subcnt + ":<a target='_blank' href='" + decode(subulrs[k]) + "' onmousedown='sd(event," + subcnt + ",this);'>" + decode(subulrs_s[k]) + "</a>";
  113.                         }
  114.                     }

  115.                     if (subcnt == 0)
  116.                         G("mu").style.display = "none";
  117.                     else
  118.                         G("more").innerHTML = str;
  119.                 }();

  120.                 -function(){
  121.                     var adh = G("adv").innerHTML.replace(/(^[\s\t\xa0 ]+)|([ \xa0\s\t]+$)/g, "") ? 300 : 0;

  122.                     var width = 600, height = 175 + adh + G("t1").offsetHeight;
  123.                     var left = (screen.width - width) / 2, top = (screen.height - height) / 2;
  124.                     moveTo(left, top);
  125.                     resizeTo(width, height);
  126.                 }();

  127.                 var mhot = {}, is_recmd = false;

  128.                  

  129.                          if(is_recmd){
  130.                                  var cnt = 0;
  131.                           
  132.                           
  133.                                  log("http://imgs.zhangmen.baidu.com/wd/mp3-sg.jpg?rf=sg-recmd&query=%E9%81%97%E5%A4%B1%E7%9A%84%E7%BE%8E%E5%A5%BD%20%20$%D5%C5%C9%D8%BA%AD&cnt=" + cnt + "&r=" + Math.random());
  134.                          }else{
  135.                                  log("http://imgs.zhangmen.baidu.com/wd/mp3-sg.jpg?r=" + Math.random());
  136.                          }

  137.                 mhot.opmb = function(pos){
  138.                                 var song = "";
  139.                     var url = "http://box.zhangmen.baidu.com/m?rf=sg-recmd&pos=" + pos + "&gate=10&ct=134217728&tn=baidumt&c_n=" + encodeURIComponent("推荐歌曲") + "&a_n=" + encodeURIComponent("相关推荐") + "&s_n=" + encodeURIComponent(song) + "&s_o=" + (pos-1) + "&query=" + encodeURIComponent("閬楀け鐨勭編濂� $张韶涵");
  140.                     var width = 870;
  141.                     var height = 650;
  142.                     var left = 0;
  143.                     var top = 0;
  144.                     var win = window.open(url, 'baidumb', 'width=' + width + ',height=' + height + ',top=' + top + ',left=' + left + ',scrollbars=0,resizable=0,status=1');
  145.                     win && win.focus();

  146.                     return false;
  147.                 };
  148.     </script>
复制代码



我想知道<a id="urln" href="" target="_blank">   这个url等到什么?

LT技术团队

夜归人Dě传奇

Rank: 7Rank: 7Rank: 7

注册时间
2008-5-25
最后登录
2012-1-13
在线时间
49 小时
阅读权限
100
积分
767
帖子
113
主题
26
精华
0
UID
5

LT粉丝

发表于 2010-9-10 10:42:22 |显示全部楼层
写了这么长的js,自己难道看不懂?
成长中的小企鹅........长......大.......中.......  

Blog:http://www.yuexiayiyu.cn

使用道具 举报

Rank: 6Rank: 6

注册时间
2009-5-7
最后登录
2012-1-17
在线时间
135 小时
阅读权限
70
积分
1819
帖子
96
主题
14
精华
0
UID
2926
发表于 2010-9-13 16:19:13 |显示全部楼层
我写的- -   就不会发上来了

使用道具 举报

Rank: 9Rank: 9Rank: 9

注册时间
2010-7-31
最后登录
2012-1-31
在线时间
9 小时
阅读权限
200
积分
392
帖子
21
主题
2
精华
0
UID
9970
发表于 2010-9-14 09:43:09 |显示全部楼层
在JS正文中未找到你说的<a id="urln" href="" target="_blank">,
不明白你想知道什么?

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

IT运维专家网感谢红之盟网络提供带宽支持

合作联系: QQ:67888954/MSN:cnseek@msn.com/mail:netseek@linuxtone.org

Archiver|手机版|感谢所有关心和支持过LinuxTone的朋友们 转载本站内容请注明原作者名及出处 ( 京ICP备08103151 )   |

GMT+8, 2012-2-4 19:15 , Processed in 0.048316 second(s), 12 queries , Memcache On.

Powered by Discuz! X2

© 2001-2011 Comsenz Inc.

回顶部