<?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
最新推荐文章于 2021-03-27 04:26:28 发布
<?php
$url = 'http://www.baidu.com';
$html = file_get_contents($url);
if(file_put_contents('baidu.html',$html)){
echo 'OK';
}else{
echo 'NO';
}
?>
解析:最简单的‘采集’