diff --git a/library/tools/add_weibo_spider_task.php b/library/tools/add_weibo_spider_task.php index a5d07b3..b01f4f7 100644 --- a/library/tools/add_weibo_spider_task.php +++ b/library/tools/add_weibo_spider_task.php @@ -3,7 +3,7 @@ include_once(dirname(dirname(__FILE__)) . "/publicBase.php"); $code = trim($argv[1]); -addTaskVideo(); +addTaskVideoId(); exit; function addTaskPic() { @@ -49,4 +49,15 @@ function addTaskVideo() { } } +function addTaskVideoId() { + $obj = new mSpider(); + $rdobj = $obj->initRedis(); + + $data = array(54545,45110,44706,44270,44267,44216,44183,42563,41626,40667,39537,39575,37161,36562,53,18557,32117,33366,33296,34889,28942,2755,34840,33946,34819,33906,13799,33153,29683,33970,33817,34761,34754,14311,25891,34714,34711,34059,29898,23725,34693,34687,33058,2900,125,33608,33,33266,34549,12032,2003,30243,29068,34420,29505,29331,5084,6957,30775,12548,33612,24167,34211,33261,33264,216,33704,31015,14602,22486,33897,34262,33275,32972,32980,29550,29145,28700,28608,27680,27269,13056,21375,7836,401,24274,4144,23995,23903,23843,23884,23796,23683,23598,23594,22927,21055,22035,21864,21840,21516,21496,12590,21163,21127,17469,21084,21053,20891,20866,16341,16990,13035,14981,16219,16198,6955,16447,15831,20399,6885,15816,4312,13661,8421,5220,15354,15327,12366,19907,14455,9462,13079,19685,19645,19644,12844,13877,3233,18894,18948,17257,7671,13786,13737,13168,12925,12887,12809,12666,12422,10139,9081,8351,8602,8560,8347,8339,8333,8167,7967,7892,7599,7689,7602,7201,7185,6263,5966,5962,5335,5309,3917,3432,2889,2818,2796,2705,1580,733,74); + + foreach($data as $v){ + $rdobj->lpush(_RQ_SPIDER_WEIBO_DATA, $v); + } +} + diff --git a/model/mSpider.php b/model/mSpider.php index 616d81d..6918e90 100644 --- a/model/mSpider.php +++ b/model/mSpider.php @@ -13,11 +13,11 @@ class mSpider extends mBase { } public function getZmhttpIp($task_key) { -// $rdobj = $this->initRedis(); -// $aa = $rdobj->get('aaa'); -// if($aa) return false; -// -// $rdobj->setex('aaa', 60, 1); + $rdobj = $this->initRedis(); + $aa = $rdobj->get('aaa'); + if($aa) return false; + + $rdobj->setex('aaa', 60, 1); $url = "http://proxy.siyetian.com/apis_get.html?token=AesJWLNp2a65kaJdXTqFFeNpWT35ERNpnTn1STqFUeORUR31kaNh3TUl0dPRUQy4ERJdXT6lVN.QMxkTO0MjM0cTM&limit=1&type=1&time=&data_format=json&showTimeEnd=true"; $jsoninfo = $this->getCUrl($url); diff --git a/model/mWeibo.php b/model/mWeibo.php index a777059..1025acb 100644 --- a/model/mWeibo.php +++ b/model/mWeibo.php @@ -47,7 +47,7 @@ class mWeibo extends mBase { $v['pic_arr'] = $pic_arr; if ($v['video_url']) $v['video_url'] = $this->getVideoOssUrl($v['wid'], $v['created_at']); - if ($v['video_cover']) $v['video_cover'] = $this->getPicOssUrl($v['wid'], $v['created_at']); + if ($v['video_cover']) $v['video_cover'] = $this->getPicOssUrl($v['video_cover'], $v['created_at']); } return $list; } diff --git a/view/js/index.js b/view/js/index.js index e7ba837..70cec36 100644 --- a/view/js/index.js +++ b/view/js/index.js @@ -97,7 +97,7 @@ $(document).ready(function () {