When file_get_contents obtains the Kugou webpage, the src of the <audio> tag is empty.
$urlBefore = "https://www.kugou.com/song/#";
foreach ($urlData as $key => $value) {
$url = $urlBefore . "hash=" . $value["hash"] ."&album_id=".$value['album_id'];
echo $url."<br/>";
$htmlFile =phpQuery::newDocumentFileHTML($ url);
$title = pq("#myAudio");
$url0 = pq($title[0])->attr("src");
print($url0." <br/>");
}
//$url0 variable is empty, the website source code can be obtained, but the value of the src attribute of the <audio> tag is unknown, is this blocked? How do I get it?
一杯水2053 days ago1055