我正在尝试在 php 中学习 WebRTC,并在 github 中找到了一个应用程序:https://github.com/amirsanni/Video-Call-App
为了运行该应用程序,我必须通过命令行运行 server.php。我完全按照开发人员所说的进行操作,即导航到目录并运行 php server.php 但是,当我运行它时,CLI 什么也不返回。它看起来像这样:
P.S: Things i tried till now:
- executing other php files returns atleast errors instead of forever blinking cursor.
- tried running from browser but no success, it keeps loading and shows blank.
最佳答案
好的,我明白了,它不应该返回任何东西。
现在我问它的原因没有返回任何内容,因为当我运行 localhost:8000 时,它说 404 not found,所以我想也许服务器没有运行,这就是它找不到文件路径的原因。
所以问题是当我提取文件夹(从我的问题中的链接下载)时,文件夹名称的前缀为“-master”,这就是它找不到路径的原因,删除它解决了问题。
关于PHP 文件通过 CLI 执行时返回空白,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50961931/