gpt4 book ai didi

php - yii应用地址

转载 作者:太空宇宙 更新时间:2023-11-04 09:55:27 26 4
gpt4 key购买 nike

我是 Ubuntu 和 PHP 框架的新手。我读过关于 Yii 的书“使用 yii 和 php 5 进行敏捷 Web 应用程序开发”。

这是文本的一部分:

Yii comes with a simple requirement checking tool. To invoke
the tool and have it verify the requirements for your installation, simply point
your browser to:
http://yourhostname/path/to/yii/requirements/index.php

我在/var/www/html/yii 目录下安装了 yii。

当我尝试打开 http://localhost/var/www/html/yii/requirements/index.php 时我收到错误消息:糟糕!此链接似乎已损坏。

感谢您的帮助!

最佳答案

这取决于您的 Apache 服务器的“webroot”(本地主机)是什么。

如果您的 webroot 是 /var/www/html 那么 el chief 的答案就可以了:

http://localhost/yii/requirements/index.php

但是你的 webroot 是 /var/www 那么你还需要包含 html 部分:

http://localhost/html/yii/requirements/index.php

基本上“localhost”=/some/path(你的 Apache webroot),当你写你的 URL 时,你可以只替换这两个。

所以如果 "localhost"= /var/www 而不是写 http://var/www/index.php 你只写 http://localhost/index.php

我希望这可以帮助您更深入地了解正在发生的事情。

关于php - yii应用地址,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5407992/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com