修复综艺采集失败

master
178146582 6 years ago
parent 8f0518d8bf
commit f747fb0f85
  1. 2
      .env.example
  2. 2
      app/Http/Controllers/IndexController.php
  3. 2
      resources/views/index.blade.php

@ -1,7 +1,7 @@
APP_NAME=Laravel
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_DEBUG=false
APP_LOG_LEVEL=debug
APP_URL=http://localhost

@ -126,7 +126,7 @@ class IndexController extends Controller {
if ($type == 'va') {
// 综艺
preg_match_all("|<a href='(.*?)' d[\s\S]*?<span class='w-newfigure-hint'>(.*?)</span>|",stristr($data,'s-month-tab'),$pages);
$preg = '|<img src="(.*?)">\r[\s\S]*?<h1>(.*?)</h1>[\s\S]*?(.*?)<p class="tag">(.*?)</p>[\s\S]*?<div class="base-item-wrap">([\s\S]*?)</div>[\s\S]*?display:none;"><span>([\s\S]*?)<a href="#"|';
$preg = '|<img src="(.*?)">\r[\s\S]*?<h1>(.*?)</h1>[\s\S]*?(.*?)<p class="tag">(.*?)</p>[\s\S]*?<span class="cat-title">([\s\S]*?)</div>[\s\S]*?display:none;"><span>([\s\S]*?)<a href="#"|';
preg_match($preg,$data,$res);
}elseif($type == 'm'){
// 电影

@ -132,7 +132,7 @@
</div>
<div class="am-u-lg-3">
<div class="am-u-lg-3" style="padding-right:0px;">
@for ($q = 0;$q < 3;$q++)
<div data-am-widget="titlebar" class="am-titlebar am-titlebar-default am-no-layout">

Loading…
Cancel
Save