设为首页收藏本站

八达网

 找回密码
 注册
查看: 155|回复: 6
打印 上一主题 下一主题

八达VOD组的大大请进

[复制链接]

23

主题

1

好友

4万

积分

光明执政官

跳转到指定楼层
1
发表于 2009-5-19 21:47 |只看该作者 |倒序浏览
我用PSP看VOD的

请问 八达所有VOD都是传到YOUKU吗?
有没有八达特有的TAG呢? 输入什么能仅搜到八达的?

23

主题

1

好友

4万

积分

光明执政官

2
发表于 2009-5-19 21:54 |只看该作者
没有在的吗?
回复

使用道具 举报

56

主题

5

好友

17万

积分

黑暗执政官

~解梦虫族~

2008年度八达十大水友 2009年度八达十大杰出青年

3
发表于 2009-5-19 21:57 |只看该作者
...下下来转换格式嘛
处女默默飘,对你们微笑一下,(*^__^*) 嘻嘻……O(∩_∩)O...哈哈...
回复

使用道具 举报

222

主题

8

好友

8万

积分

管理员

理论上的巨人,行动上的胖子

Rank: 9Rank: 9Rank: 9Rank: 9Rank: 9

战队
FS-
联赛ID
FS-sy.P
种族
Protoss

2013年夜饭

4
发表于 2009-5-19 21:59 |只看该作者
没明白什么意思,
你是说你要在youku看?
为什么不在vod.sc2.com.cn看?
回复

使用道具 举报

23

主题

1

好友

4万

积分

光明执政官

5
发表于 2009-5-19 22:01 |只看该作者
没明白什么意思,
你是说你要在youku看?
为什么不在vod.sc2.com.cn看?
syp 发表于 2009-5-19 21:59

PSP有个软件 只能进到YOUKU 用它的搜索引擎搜到  可以在线直接看 不用下载
不能到八达 除非有达人能把那个JAVASCRIPT的脚本改一下
PSP不能在WEB网站上看
回复

使用道具 举报

皇太子 该用户已被删除
6
发表于 2009-5-19 22:03 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
回复

使用道具 举报

23

主题

1

好友

4万

积分

光明执政官

7
发表于 2009-5-19 22:04 |只看该作者
脚本如下
我不知道怎么改成专看八达VOD…… 这个也是别人改成可以看YOUKU的 以前是YOUTUBE的

function YouKu_CheckURL( url, option )
{
  if(url.match( /youku/ ))
  {
    return 1;
  }
  else
  {
  
    return 0;
  }
}

function YouKu_GetURL( url, option )
{
  url.match( /(.*?)_part_(\d*)/ );
  var surl="http://www.flvcd.com/parse.php?kw=" + RegExp.$1 + "&flag=";
  
  var part = parseInt( RegExp.$2 ) - 0;
  var pos = 0;
  var contents = GetContents( surl );
   if( contents == null)
      alert("contents null");
   
  var video_url = contents.match(/<a\shref\=\"(.*?)\"\starget.*?false\;\">/g);
  //alert(RegExp.$1);
  if( video_url != null)
  {
    video_url[part - 1].match(/<a\shref\=\"(.*?)\"\starget.*?false\;\">/);
    //alert(RegExp.$1);
    return RegExp.$1;
  }
  else
  {
    alert(RegExp.$1);
    return null;
  }
}

function YouKu_Search( keyword, start_index, length, option )
{
  var nPage = Math.floor(( start_index-1)/length+1);
  var nIndex = (nPage - 1) * 2 + 1;
  var pattern = /<ul\sclass\=\"video\">((.|\r|\n)*?)<\/ul>/g;
  var result = new Object(keyword);
  keyword = PYtoGBK(keyword);
  keyword = GBKtoUTF8(keyword);
  result.keyword   = keyword;  
  result.VideoInfo = new Array();
  result.start     = nIndex;
  result.end       = 0;
  result.total     = -1;
  var sort = 1;  
  var ss = "s";
  //ex.) http://so.youku.com/search_video/q_54_orderby_1_page_8.html
  var url_base = "http://so.youku.com/search_video/q_";
  if(keyword.match(/\/([stpnm])/))
  {
    ss = RegExp.$1;
  //ss = String(keyword.substring(keyword.length-1, keyword.length));
    keyword = RegExp.leftContext;
  }
else
  if(keyword.match(/\//))
  {
  
  keyword = RegExp.leftContext;
  }
  if (ss != "s")
  {  
   
    if (ss == "t") sort = 2;
    if (ss == "p") sort = 3;
    if (ss == "n") sort = 5;  
    if (ss == "m") sort = 4;
  
  }
  
  
  
  url_base = url_base + PSPTube.encodeURI( keyword )+"_orderby_" + "2" + "_page_";  
  
var n = Math.floor( (nIndex - 1) / 12 ) + 1;
  var nn = (n - 1) * 12 + 1;
var i = nn;
  while(i < (nIndex + 2))
   {
   if( Math.floor((i-1)/12+1) > n) n = n+1;
    var url = url_base + String( n )+".html";     
    var contents = GetContents( url );
    if(contents == null) { alert("contents null");return null; }
    if(contents.match( /共找到\s<span\sclass\=\"num\">(\d*?)<\/span>/ ))
    {
      result.total = RegExp.$1 - 0;
    }
   
   
    while(pattern.exec( contents ) != null)
    {
      if((nIndex <= i) && (i < (result.start + 2)))
      {
        
        var item = RegExp.$1;
        var info = new Object();
        

        if(item.match( /target\=\"video\"\stitle\=\"(.*?)\"/ ))
         {
          info.Title = RegExp.$1;
          //info.Title = info.Title.replace( /<.*?>/g, "");
          info.Title = UTF8ToUnicode(info.Title);
          info.Title = traditionalizedUnicode(info.Title);
          info.Title = UnicodeToUTF8(info.Title);   

          }
      

        if(item.match( /<img\ssrc=\"(.*?)\"\salt\=.*/ ))
        {
          info.ThumbnailURL = RegExp.$1;
        }
      
          //if(item.match( /<li\sclass\=\"videoImg\"><a\shref\=\"(.*?)\"\scharset/ )) {
        if(item.match( /<li\sclass\=\"videoImg\"><a\shref\=\"(.*?)\"\scharset/ ))
         {
          info.URL = RegExp.$1;
        }
        
        if(item.match( /<li\sclass=\"vIntro\">(.*?)<\/li>/ ))
         {
          var Description = RegExp.$1;
         
          info.Description = Description;
     
        }
      
        
        
        if(item.match( /<li>播放:\s<span\sclass\=\"num\">(.*?)<\/span>/ ))
        {
          var vc = RegExp.$1.replace("," , "");
          info.ViewCount = parseInt(vc) - 0;
        }
        
        if(item.match( /<li>评论:\s<span\sclass\=\"num\">(.*?)<\/span>/ ))
         {
          var vc = RegExp.$1.replace("," , "");
          info.CommentCount = parseInt(vc) - 0;
        }
        
        if(item.match( /<span\sclass\=\"num\">(\d{1})\\d{2})\\d{2})<\/span>/ ))
         {
          info.LengthSeconds = (RegExp.$1 - 0) * 3600 + (RegExp.$2 - 0) * 60 + (RegExp.$3 - 0);
        }
            
        info.attr = 7;
        
        //分段
        var part = Math.floor( info.LengthSeconds  / 412 ) + 1;
        var count = 1;
        while( part > 0 ) {
          var info_part = new Object();
          info_part.Title = info.Title + "_part_" + String(count);
          info_part.ThumbnailURL = info.ThumbnailURL ;
          info_part.Description = info.Description ;
          info_part.ViewCount = info.ViewCount ;
          info_part.CommentCount = info.CommentCount ;
          info_part.LengthSeconds = info.LengthSeconds ;
          info_part.URL = info.URL + "_part_" + String(count) ;
          info_part.attr = info.attr ;
          count++;
          part--;
          result.VideoInfo.push( info_part );
        }
      }
      i++;
    }

  }

  if(result.VideoInfo.length) {
    result.end   = result.start + (result.VideoInfo.length - 1);
  } else {
    result.total = 0;
  }
  return result;
}

var YouKu = new Object();
YouKu.Name          = "YouKu";
YouKu.Description   = "YouKu";
YouKu.SearchDesc    = "YouKu";
YouKu.SearchOSKMode = 2;
YouKu.CheckURL      = YouKu_CheckURL;
YouKu.GetURL        = YouKu_GetURL;
YouKu.Search        = YouKu_Search;

SiteList.push( YouKu );
回复

使用道具 举报

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

手机版|Archiver|八达网    

GMT+8, 2026-2-9 03:31

Powered by Discuz! X2.5

© 2001-2012 Comsenz Inc.

回顶部