如何通过htaccess的设置默认网站的页面?
我目前建立在他的托管帐户来自客户端的网站。该网站的地址,由于某种原因不默认为.php文件(即:的index.php)。如果我把index.php文件并没有收到以下错误index.html文件:
I am currently setting up a website from a client on his hosting account. The website address and for some reason doesn't default to .php files (that is: index.php). If I put index.php and there is no index.html file I receive the following error:
如果你觉得你已经达到这页错误,请联系 网站所有者:someemail@example.com如果您是网站所有者, 有可能你已经到达了该网页,因为:IP地址具有 改变。已经有一台服务器配置错误。该网站可能有 被移动到另一台服务器。如果您是此网站的所有者 并没有想到要看到这个页面,请联系您的主机 供应商。
If you feel you have reached this page in error, please contact the web site owner: someemail@example.com If you are the web site owner, it is possible you have reached this page because: The IP address has changed. There has been a server misconfiguration. The site may have been moved to a different server. If you are the owner of this website and were not expecting to see this page, please contact your hosting provider.
他的主机是一个共享的主机上的cPanel。
His hosting is a shared hosting on cpanel.
使用DirectoryIndex指令在你的.htaccess文件
Use the DirectoryIndex directive in your .htaccess file
DirectoryIndex index.php