<?php
$url = 'http://www.baidu.com';
$html = file_get_contents($url);
if(file_put_contents('baidu.html',$html)){
echo 'OK';
}else{
echo 'NO';
}
?>
解析:最简单的‘采集’
file_get_contents
最新推荐文章于 2020-11-19 13:50:24 发布
<?php
$url = 'http://www.baidu.com';
$html = file_get_contents($url);
if(file_put_contents('baidu.html',$html)){
echo 'OK';
}else{
echo 'NO';
}
?>
解析:最简单的‘采集’