|
...
|
...
|
@@ -32,9 +32,15 @@ class TestController extends BaseController |
|
|
|
<p> </p>
|
|
|
|
<p><a href="tel:+86%2018825057975">Tel:+86 18825057975</a></p>
|
|
|
|
<p><a href="mailto:edinguas@gmail.com">Email:edinguas@gmail.com</a></p>';
|
|
|
|
$newsLogic = new NewsLogic();
|
|
|
|
$key = $newsLogic->processImage($test);
|
|
|
|
$this->response('success',Code::SUCCESS,['key'=>$key]);
|
|
|
|
}
|
|
|
|
$pattern = '/<img\s+[^>]*src=["\']([^"\']+)["\']/i';
|
|
|
|
$matches = [];
|
|
|
|
// Use preg_match_all to find all src attributes
|
|
|
|
preg_match_all($pattern, $inputString, $matches);
|
|
|
|
|
|
|
|
// Return an array of all src URLs found
|
|
|
|
return $matches[1];
|
|
|
|
// $newsLogic = new NewsLogic();
|
|
|
|
// $key = $newsLogic->processImage($test);
|
|
|
|
$this->response('success',Code::SUCCESS,$matches[1]);
|
|
|
|
}
|
|
|
|
} |
...
|
...
|
|