$url = 'http://product.dangdang.com/23812052.html';
$str = file_get_contents($url);//抓取函数
preg_match_all('/(?<=[<li tag=\"\d{1}\"> <a href=\"javascript:;\" imghref=\".*\">]) <img[^>]*src=[\'"]*([^\'"]*)[\'"][^>]*>(?=[<\/a> <\/li>])/is', $str , $ar );//正则你想要的数据
$strs =array_unique($ar[1]);//移除数组中的重复值