Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
Thread: home page
05-21-2004, 07:07 PM #2
- Join Date
- Jun 2002
- Winona, MN - The land of 10,000 lakes
- Thanked 45 Times in 42 Posts
Depends, what are you using for a web server? Apache? IIS?
05-21-2004, 07:11 PM #3
- Join Date
- May 2002
- Marion, IA USA
- Thanked 83 Times in 82 Posts
Assuming you are using Apache webserver....
Well if you are allowed to use .htaccess files you can change the default index page to whatever you want. What you would do is create a .htaccess file and put it in the root folder of your webspace. The commands will apply to all subdirectories as well as the current directory it is placed in.
As for the command to put in the file you simply need this:
You can add more to the list if you need them. For example:
DirectoryIndex home.php index.php index.html home.html foobar.htm
What happens is when a directory is requested by the browser it will go through this list from left to right and look for a matching file in that directory. Now if for some reason you happened to have more than one of those files listed actually in the directory I think the ones listed first have priority. So for example if you had both an home.php and a index.php it would go to home.php since it is listed first in that list.
CodingForums Supreme Overlord
All Hail Spookster