asfman
android developer
posts - 90,  comments - 213,  trackbacks - 0
<html XMLNS:HTA>
<head>
<title>hello world</title>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<script language="JScript">
window.onerror=function(){return true}
window.resizeTo(890, 560);
moveTo((screen.availWidth - 880) / 2, (screen.availHeight - 560) / 2);
function document.onkeydown(){
 if(event.ctrlKey && event.keyCode==78){
  event.keyCode=0;event.returnValue=false;
 }
}
</script>
<HTA:APPLICATION
  ID="IniCtrlApp"
  ICON="magnify.exe"
/>
<style type="text/css">
* {
 font-size:11px;
 font-family:verdana;
}
body {
 border:0px;
 margin:4px;
 background:menu;
}
.input-text {
 border:1px solid #000000;
 height:20px;
 margin:0px 0px 0px 2px;
 width:220px;
 line-height:18px;
}
.input-button {
 border-top:1px solid #FFFFFF;
 border-left:1px solid #FFFFFF;
 border-right:1px solid #000000;
 border-bottom:1px solid #000000;
 height:20px;
 margin:0px 10px 0px 2px;
 line-height:18px;
}
select, .plays {
 width:100%;
 height:expression(document.body.clientHeight - 78);
}
#swfdiv{
width:500px;
height:450px;
overflow-x:hidden;
}
.tudou{
margin-left:-250px;
}
#ld{
margin-right:200px;
}
</style>
<script language="JScript">
function getHtml(str){
 var rs = new ActiveXObject("ADODB.RecordSet");
 rs.fields.append("a", 201, 1);
 rs.open();
 rs.addNew();
 rs(0).appendChunk(str);
 rs.update();
 return rs("a").value;
}
function run(url, obj){
 var obj = document.getElementById(obj);
 var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
 xmlhttp.open("get",url,true);
 xmlhttp.onreadystatechange = func.call(xmlhttp,url,obj);
 xmlhttp.send();
}
function func(url,o)
{
    var xmlhttp = this;
    return function()
    {
        if(xmlhttp.readyState == 4)
        {
            if(xmlhttp.status == 200 || xmlhttp.status == 0)
            {
                var musicAddr = getHtml(xmlhttp.responseBody);
          ifr.document.body.innerHTML = musicAddr;
          musicAddr = ifr.document.getElementsByTagName("a");
          o.innerHTML = "";
          for(i = 0; i < musicAddr.length; i ++)
          {
           if(/(\w+)\/(\d+)$|play\d+\.html$/.test(musicAddr[i].href))
           {
           var addop = document.createElement("option");
         var suffix = RegExp["$&"];
        addop.value = url.replace(/[^\/]*\.html$/i,"") + "/" + suffix;
        addop.value = addop.value.replace(/\/\/(?!www)/g,"/");
        addop.innerText = musicAddr[i].innerText;
        o.appendChild(addop);
           }
          }
            ifr.document.body.innerHTML = "";
            document.getElementById("ld").innerHTML  = "加载成功!".fontcolor("red");
            }else
            {
                 document.getElementById("ld").innerHTML = "由于网络问题,加载失败...".fontcolor("red");
            }
        }
        else
        {
                 o.options[0].innerText = "正在加载...";
                 document.getElementById("ld").innerHTML = "正在加载...".fontcolor("red");
        }
    }
}
function search(str){
 var t = document.getElementById("tex").options;
 var iFlag = false;
 for(var i = 0; i < t.length; i ++){
  if(t[i].text.indexOf(str) != -1){
   t[i].selected = true;
   iFlag = true;
   
  }
  else{
   t[i].selected = false;
  }
 }
 if(!iFlag)alert(" 对不起,没有搜到你输入的电影!");
}
function play(url){
 var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
 xmlhttp.open("get",url,false);
 xmlhttp.send();
 document.getElementById("swfdiv").innerHTML = "";
 var musicAddr = getHtml(xmlhttp.responseBody);
 if(/url ="n_/i.test(musicAddr))
 {
  musicAddr = musicAddr.match(/url ="n_(.*?)"/)[1];
  play56(musicAddr,'500','450');
 }
 else
 {
    var n = musicAddr.match(/url =\"(\d+)\"/)[1];
    if(/play\/tudou\.htm/.test(musicAddr))
    {
       playTD(n,'750','450');
    }else
    {
    playYk(n,'500','450');
    }
 }
}
function playYk(url,w,h){
 document.getElementById("swfdiv").innerHTML = '<embed type="application/x-shockwave-flash" src="http://static.youku.com/v1.0.0182/v/swf/qplayer.swf" id="movie_player" name="movie_player" bgcolor="#FFFFFF" quality="high" allowfullscreen="true" flashvars="isShowRelatedVideo=false&showAd=0&show_pre=1&show_next=1&VideoIDS='+url+'&isAutoPlay=true&isDebug=false&UserID=&winType=interior&playMovie=true&MMControl=false&MMout=false&RecordCode=1001,1002,1003,1004,1005,1006,2001,3001,3002,3003,3004,3005,3007,3008,9999" pluginspage="http://www.macromedia.com/go/getflashplayer" width="'+w+'" height="'+h+'">';
}
function playTD(url,w,h){
var str = "";
str += ('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="'+w+'" height="'+h+'" align="middle">');
str += ('<param name="allowScriptAccess" value="always">');
str += ('<param name="allowFullScreen" value="true">');
str += ('<param name="movie" value="http://ui.tudou.com/bin/player.swf">');
str += ('<param name="flashvars" value="iid='+url+'">');
str += ('<embed src="/static/bin/player.swf" flashvars="iid='+url+'" allowFullScreen="true" allowScriptAccess="always" quality="high" bgcolor="#ffffff" width="'+w+'" height="'+h+'" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">');
str += ('</object>');
document.getElementById("swfdiv").innerHTML = "<div class='tudou'>" + str + "</div>";
}
function play56(url,w,h)
{
var url2=url.split('_/');
var str = "";
str += ('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+w+'" height="'+h+'">');
str += ('<param name="allowScriptAccess" value="always" />');
str += ('<param name="movie" value="http://www.56.com/flashApp/v_player_site.swf">');
str += ('<param name="FlashVars" value="&img_host='+url2[0]+'.56.com&host='+url2[1]+'.56.com&pURL='+url2[2]+'&sURL='+url2[3]+'&user='+url2[4]+'&user_id='+url2[4]+'&URLid='+url2[5]+'&tag=&Subject=&totaltimes='+url2[6]+'&effectID='+url2[7]+'&flvid='+url2[8]+'&56.swf">');
str += ('<param name="quality" value="high">');
str += ('<param name="allowFullScreen" value="true">');
str += ('<param name="bgcolor" value="#ffffff">');
str += ('</object>');
document.getElementById("swfdiv").innerHTML = str;
}
</script>
</head>
<body scroll="no" onselectstart="if(document.activeElement.tagName!='INPUT' && document.activeElement.tagName!='A')return false;" onContextmenu="if(document.activeElement.tagName!='INPUT' && document.activeElement.tagName!='A')return false;">
<table width="100%" border="0">
 <tr>
  <td width="20%">
  <fieldset style="padding:5px;width:100%"><legend>搜索结果</legend>
   <select name="tex" id="tex" multiple="true" ondblclick="run(this.value, 'mis')">
    <option id="ts">搜索程序已准备就绪!</option>
   </select>
  </fieldset>
  </td>
  <td width="1%">
  </td>
  <td width="20%">
  <fieldset style="padding:5px;width:100%"><legend>播放列表</legend>
   <select name="mis" id="mis" multiple="true" ondblclick="play(this.value)">
   </select>
  </fieldset>
  </td>
  <td width="1%">
  </td>
  <td width="58%">
  <fieldset style="padding:5px;width:100%"><legend>播放器</legend>
   <div class="plays">
    <span id="swfdiv">
    </span>
   </div>
  </fieldset>
  </td>
 </tr>
 <tr>
  <td colspan="5">
  <fieldset style="padding:5px">
   <div style="width:100%;text-align:right;padding:3px;"><span id="ld"></span>&nbsp;<input class="input-text" type="text" id="search" />&nbsp;
   <input class="input-button" type="button" onclick="search(document.getElementById('search').value)" value="搜 索" />&nbsp;
    <!--marquee scrollamount="3" onmouseover="this.stop();" onmouseout="this.start();"-->
    <a href="###" onclick="run('http://www.haokan.cc/allmovie.html', 'tex');">
    按这里载入...</a>&nbsp;&nbsp;欢迎大家访问<a href="http://www.21cp.net/" target="_blank">http://www.21cp.net</a>&nbsp;&nbsp;&nbsp;&nbsp;
    <!--/marquee-->
   </div>
  </fieldset>
  </td>
 </tr>
</table>
<iframe src="about:blank" application="no" trusted="false" style="display:none" id="ifr" name="ifr"></iframe>
</body>
</html>
posted on 2008-03-13 15:42 汪杰 阅读(490) 评论(0)  编辑 收藏 引用 所属分类: others
只有注册用户登录后才能发表评论。

<2008年11月>
2627282930311
2345678
9101112131415
16171819202122
23242526272829
30123456

常用链接

留言簿(15)

随笔分类(1)

随笔档案(90)

文章分类(727)

文章档案(712)

相册

收藏夹

http://blog.csdn.net/prodigynonsense

友情链接

最新随笔

搜索

  •  

积分与排名

  • 积分 - 457959
  • 排名 - 6

最新随笔

最新评论

阅读排行榜

评论排行榜