我得到多張圖片我如何可以使用下面的腳本如何使用URL
<?php
$url = 'http://stackoverflow.com/questions/7994340/how-can-i-get-image-from-url-in-php-or-jquery-or-in-both';
$data = file_get_contents($url);
if(strpos($data,"<img"))
{
$imgpart1 = explode('<img src=',$data);
$imgpart2 = explode('"',$imgpart1[1]);
echo "<img src=".$imgpart2[1]." />";
}
?>
請幫助獲得多個圖像!
我建議使用['DOMDocument'](http://php.net/manual/en/class.domdocument.php)解析HTML,verus使用字符串搜索。 –