我創建一個PHP代碼使用的file_get_contents得到從這個網頁標籤「hlsUrl」第一M3U8鏈接,但它不工作,任何幫助,請的file_get_contents但空載
我的代碼是
> <?php
>
> $link =
> "https://stream.live/-/streams/users/kawkaw?includeTrending=true" ;
>
> $actualLink = file_get_contents($link);
> echo $actualLink->find("hlsUrl");
>
> ?>
'$ actualLink'是一個字符串,而一個字符串沒有函數'find'。 – Jerodev
'file_get_contents'將返回字符串,所以沒有'find'方法。首先解析它 – Justinas
此外,爲了將來的參考,說*「但它不工作」*對任何人都沒有幫助。向我們顯示錯誤消息。 –