作者 刘锟

合并分支 'akun' 到 'master'

Akun



查看合并请求 !167
... ... @@ -390,6 +390,7 @@ class HtmlCollect extends Command
$js_html = curl_c(getImageUrl($new_source), false);
preg_match_all("/[large|thumb]+URL:['\"]+(\s*[^>]+?)['\"]+,/i", $js_html, $result_js_source);
$js_source = $result_js_source[1] ?? [];
if($js_source){
foreach ($js_source as $vjs) {
$vjs_result = $this->url_check($vjs, $project_id, $domain, $web_url_domain, $home_url);
if (!$vjs_result) {
... ... @@ -416,11 +417,13 @@ class HtmlCollect extends Command
CosService::uploadRemote($project_id, 'source', $new_source, $new_source, $js_html);
}
}
}
} elseif(substr($vs['url_complete'], -2, 2) == 'js') {
$js_html = curl_c(getImageUrl($vs['url_complete']), false);
preg_match_all("/[large|thumb]+URL:['\"]+(\s*[^>]+?)['\"]+,/i", $js_html, $result_js_source);
$js_source = $result_js_source[1] ?? [];
if($js_source){
foreach ($js_source as $vjs) {
$vjs_result = $this->url_check($vjs, $project_id, $domain, $web_url_domain, $home_url);
if (!$vjs_result) {
... ... @@ -445,6 +448,7 @@ class HtmlCollect extends Command
}
CosService::uploadRemote($project_id, 'source', $vs['url_complete'], $vs['url_complete'], $js_html);
}
}else{
$html = str_replace($vs['url'], getImageUrl($vs['url_complete']), $html);
}
... ...