Welcome to WebmasterWorld Guest from 54.226.25.231

Forum Moderators: phranque

Message Too Old, No Replies

Index page

     

zxk105

2:11 am on Sep 21, 2004 (gmt 0)

10+ Year Member



I am planning to use php to implement a site. I was wondering whether index/default page always has to be *.html/*.htm or can it be *.php also? I hope it can also have php extension but I don't know. Thanks

filmfodder

2:52 am on Sep 21, 2004 (gmt 0)

10+ Year Member



I've encountered similar issues. My hosting company made a few tweaks on the server side and I've been able to set my "default" to .html, .htm and .asp. I imagine something similar could be done for .php.

Hope that helps!

vkaryl

3:26 am on Sep 21, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I haven't had the problem, because my host has always implemented .php as well as all the rest for index pages. Maybe they're a lot more rara avis than I realized?

zxk105

3:36 am on Sep 21, 2004 (gmt 0)

10+ Year Member



So I should just try naming the page default.php and see whether it works or not. Hopefully it will. If not I'll be back to post another message. Thanks guys....

sonjay

3:51 am on Sep 21, 2004 (gmt 0)

10+ Year Member



The index/default page can be set on the server to be anything you want -- including monkey.butt.

It's generally set server-wide to include a list of filenames in a particular order: index.htm, index.html, index.php, index.shtml, default.htm, etc. The server will look for the pages in the order listed. If it finds the first one, it serves it up. If it doesn't, it looks for the second, and so on. So generally, if you use index.php, just make sure there's no index.htm or index.html, and it'll probably use index.php.

If your site is on a *nix box, you can also set the default page for your site in your .htaccess file, if your host allows it, or for a specific directory of your site.

You'd have to find out from your host what their server-side settings are, and if they allow you to use .htaccess.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month