获取网页源代码

优质
小牛编辑
118浏览
2023-12-01
<?php
$http = HttpRequest::newSession();
$response = $http->get('http://www.baidu.com/');
$content = $response->body(); // 网页源码