[英]Don't have access to index.html on apache?
I'm running Apache/2.2.15 (Red Hat) Server (I think). 我正在运行Apache / 2.2.15(红帽)服务器(我认为)。 When I ssh in and run grep apache, there's no output.
当我ssh并运行grep apache时,没有输出。 But...another file (index.php, read below) on the same machine/ip/directory is showing.
但是...显示了同一台机器/ ip /目录上的另一个文件(index.php,如下所示)。
I'm actually taking over for someone. 我实际上是要接管某人。 Site/pages are kept at /var/www/html.
网站/页面保存在/ var / www / html。 In that directory there are index.php and index.html.
在该目录中有index.php和index.html。 I was able to reach both.
我能够达到两者。
I changed index.html to welcome page and uploaded and replaced the old one. 我将index.html更改为欢迎页面,并上传并替换了旧的页面。 When attempting to reach index.html from another computer, I recieve the following:
当尝试从另一台计算机访问index.html时,我收到以下信息:
Forbidden
You don't have permission to access /index.html on this server.
But I can still reach index.php in the same directory. 但是我仍然可以在同一目录中访问index.php。 In case it matters, I used 'cp' copy index.html from another directory into /var/www/html.
万一重要,我使用了“ cp”将index.html从另一个目录复制到/ var / www / html。
I'm pretty new to this. 我对此很陌生。 Can someone clue me in?
有人可以告诉我吗? Thanks!
谢谢!
Not sure what the problem was but... 不知道是什么问题,但是...
When I used a text editor besides text wrangler, it worked. 当我使用文本编辑器之外的文本编辑器时,它可以工作。
When I created all the folders on the server and moved the files to the folders individually, it worked. 当我在服务器上创建所有文件夹并将文件分别移动到这些文件夹时,它可以工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.