Jump to content


Photo

changing homepage to something other than index


  • Please log in to reply
5 replies to this topic

#1 nadz

nadz
  • Members
  • PipPipPip
  • Advanced Member
  • 75 posts

Posted 18 March 2006 - 12:53 PM

hi, ive recently installed the shockarcade on my website. it took me a while but i finally got everything working. the only problem is that all the files have to be in the root directory. the main file for the script is index.php so now when ever someone accesses my site the first page they see is the shockarcade page. ive tried renaming the schock arcade index.php file so that the homepage is my original index.htm but then the games dont work. i need to know how i can change the homepage so that whenever someone accesses my site they see index.htm rather than index.php. any help would be appreciated.

thanks

#2 Kris

Kris
  • Staff Alumni
  • Advanced Member
  • 2,755 posts
  • LocationThe Internet

Posted 18 March 2006 - 01:13 PM

The default page name is set in the Apache configuration file httpd.conf - If you are on anything but a dedicated server, or you run your own server, I doubt your host will alter this.

You might be able to do something with a .htaccess file to alter this in your sites root, or it might even be worth playing with redirects in your scripts. Something like a meta refresh, or maybe with php's header() function?

#3 nadz

nadz
  • Members
  • PipPipPip
  • Advanced Member
  • 75 posts

Posted 18 March 2006 - 01:19 PM

o well, thanks anyway. i was just thinking, my real homepage was an index.htm file but when the index.php file went into the root directory it became the homepage instead, the index.htm file is still there its just no longer the homepage. in the same way is it possible theres another format of webpage that has preference over an index.php file?

#4 Kris

Kris
  • Staff Alumni
  • Advanced Member
  • 2,755 posts
  • LocationThe Internet

Posted 18 March 2006 - 01:33 PM

[!--quoteo(post=356152:date=Mar 18 2006, 01:19 PM:name=nadz)--][div class=\'quotetop\']QUOTE(nadz @ Mar 18 2006, 01:19 PM) View Post[/div][div class=\'quotemain\'][!--quotec--]in the same way is it possible theres another format of webpage that has preference over an index.php file?[/quote]
Again, this would be outlined in httpd.conf - Might be worth asking your host to see what preference order your index files are in.

#5 nadz

nadz
  • Members
  • PipPipPip
  • Advanced Member
  • 75 posts

Posted 18 March 2006 - 02:58 PM

rite, thanks alot ill contact my host and see what he says.

#6 v-wdd

v-wdd
  • New Members
  • Pip
  • Newbie
  • 6 posts
  • Location127.0.0.1

Posted 18 March 2006 - 06:10 PM

Add this line to the .htaccess file in the directory you want:
DirectoryIndex filename.ext
Replace "filename" and "ext" to whatever file you want to use as the index page.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users