如何从一个目录访问codeigniter文件到另一个不同的目录

发布于 2024-08-24 23:36:24 字数 199 浏览 2 评论 0原文

我安装了 XAMP,htdocs 位于 D 盘。我将 Codeigniter/System 文件夹复制到 E 盘。现在,当我输入 http://localhost 时,我应该能够访问 E:/Codeigniter/System/index.php 我怎样才能做到这一点。

I have XAMP installation, with htdocs in D drive. I copied Codeigniter/System folder to E drive. Now when i type http://localhost, i should able to access E:/Codeigniter/System/index.php
How can i achieve this.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

南街女流氓 2024-08-31 23:36:24

快速而肮脏:
打开 httpd.conf(通常位于 /XAMPINSTALLDIR/apache/conf 中),将所有出现的“D:/xampp/htdocs”替换为“E:/Codeigniter”,然后重新启动 apache 服务器。您应该能够通过此 URL http://127.0.0.1

更明智的方式访问您安装的 codeigniter:< /强>
了解 apache 虚拟主机 (http://httpd.apache.org/docs/2.1/vhosts /)并添加具有适当文档根目录的新虚拟主机。

Quick and dirty:
open httpd.conf (usually located in /XAMPINSTALLDIR/apache/conf), replace all "D:/xampp/htdocs" occurrences with "E:/Codeigniter" and restart your apache server. You should be able to access your codeigniter installation by this URL http://127.0.0.1

more sensible:
Learn about apache virtual hosts (http://httpd.apache.org/docs/2.1/vhosts/) and add a new virtual host with the appropriate document root.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文