正在显示
1 个修改的文件
包含
2 行增加
和
1 行删除
| @@ -247,7 +247,7 @@ class HtmlCollect extends Command | @@ -247,7 +247,7 @@ class HtmlCollect extends Command | ||
| 247 | ]); | 247 | ]); |
| 248 | $html = str_replace($vs['url'], getImageUrl($new_source), $html); | 248 | $html = str_replace($vs['url'], getImageUrl($new_source), $html); |
| 249 | 249 | ||
| 250 | - if (substr($new_source, -1, 3) == 'css') { | 250 | + if (substr($new_source, -3, 3) == 'css') { |
| 251 | // 下载css文件中的资源 | 251 | // 下载css文件中的资源 |
| 252 | $css_html = file_get_contents($vs['url_complete']); | 252 | $css_html = file_get_contents($vs['url_complete']); |
| 253 | preg_match_all("/url\(['\"](\s*[^>]+?)['\"]\)/i", $css_html, $result_css_source); | 253 | preg_match_all("/url\(['\"](\s*[^>]+?)['\"]\)/i", $css_html, $result_css_source); |
| @@ -261,6 +261,7 @@ class HtmlCollect extends Command | @@ -261,6 +261,7 @@ class HtmlCollect extends Command | ||
| 261 | //不是相对路径,不下载 | 261 | //不是相对路径,不下载 |
| 262 | continue; | 262 | continue; |
| 263 | } | 263 | } |
| 264 | + $vcs = $vcs['path']; | ||
| 264 | 265 | ||
| 265 | $source_info = CollectSource::where('project_id', $project_id)->where('origin', $vcs)->first(); | 266 | $source_info = CollectSource::where('project_id', $project_id)->where('origin', $vcs)->first(); |
| 266 | if ($source_info) { | 267 | if ($source_info) { |
-
请 注册 或 登录 后发表评论