Dear All
I've set up my Apache server to pass any file without an extension as a PHP script. This is great, but when I just type the plain domain name without any /file.php into my browser, it says " you are forbidden to access '/' ", rather than automatically directing to 'index' on the root of the server.
How can I make the server direct to 'index' on just typing the domain name?
Many thanks
Mark
Index.html/php/etc problem
Moderator: General Moderators
- Lord Sauron
- Forum Commoner
- Posts: 85
- Joined: Tue Apr 20, 2004 5:53 am
- Location: Tilburg, NL
Localhost
Try typing 'localhost' instead of a url. This will help 
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
have you setdirective?
Code: Select all
DirectoryIndex- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
Code: Select all
DirectoryIndex index.php index.html index.shtml #and so on...for your case it would be:
I'd recommend you instead of setting your Apache to parse files without extension as php use MultiViews directive. This way you can have your php files named filename.php but still access it without the extension in url.
Code: Select all
DirectoryIndex index # you can add another dir-indices as well