时间:2021-07-01 10:21:17 帮助过:13人阅读
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL, 'http://mmcfood.1x.net/');
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2 GTB5');
- $htmls = curl_exec($ch);
- curl_close($ch);
- preg_match("#]*)>(.*?)<table width="\"1079\"" ([^=""></table>#is", $htmls, $matches);
- echo $matches[0];