我只安装在Ubuntu一个Apache 2.4 & PHP 5.5.6 12.04阿帕奇2.4错误404
当我打电话的web浏览器的页面 - >mysite.com/index.php
,网页通常与作品展示,但如果我叫页面mysite.com
(没有/index.php)我得到错误404
,Apache不会自动加载index.php。
我需要在浏览器的导航栏中写这个(该网站也有一个index.html
)。我的虚拟主机mysite.conf
是:
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /home/alexbk/webs/mysite
ErrorLog /home/alexbk/webs/mysite/error.log
CustomLog /home/alexbk/webs/mysite/access.log combined
<Directory /home/alexbk/webs/mysite>
Options Indexes FollowSymLinks MultiViews
Require all granted
AllowOverride All
</Directory>
</VirtualHost>
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet -->
该文件夹没有和htacess文件。我尝试更改apache2.conf
,但没有运气。
感谢您的帮助
看到这篇文章:http://stackoverflow.com/questions/2384423/index-php-not-loading-by-default –