Results 1 to 6 of 6

Thread: index.php not picked up as default page

  1. #1
    Registered User
    Join Date
    May 2007
    Posts
    1

    Angry index.php not picked up as default page

    I have set up a wordpress blog in my website. It seems to working fine. The only problem is that index.php is not being picked up as the default page in the wordpress directory. I have to actually type index.php at the end of the URL. I have the same problem with the admin area.

    I thought that index files were automatically set to be the default files whenever you visit a directory. Do I need to change a setting?

  2. #2
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,295
    cPanel/WHM Access Level

    Root Administrator

    Default

    You might want to check your Apache Configuration, ensure that index.php is listed in the DirectoryIndex directive.

    Of course, nothing stops you from just creating a .htaccess file in that directory with the DirectoryIndex directive in it - but that's more a kludge than a solution.

  3. #3
    Registered User
    Join Date
    Mar 2004
    Posts
    2

    Exclamation

    In my case "index.php" is listed in the "DirectoryIndex directive", however, if there is an ".htm*" file in that directory, it is displayed first. How can I tell Apache to display the "index.php" first, if it exists along with an .htm file? I tried placing it first in the list, but no joy!

  4. #4
    Registered Member
    Join Date
    Sep 2006
    Posts
    28

    Default

    Quote Originally Posted by jrafuse View Post
    In my case "index.php" is listed in the "DirectoryIndex directive", however, if there is an ".htm*" file in that directory, it is displayed first. How can I tell Apache to display the "index.php" first, if it exists along with an .htm file? I tried placing it first in the list, but no joy!
    Hello,

    Please create .htaccess file and add following line in it.

    DirectoryIndex index.php

  5. #5
    Registered Member
    Join Date
    Dec 2003
    Location
    France
    Posts
    302
    cPanel/WHM Access Level

    Root Administrator

    Default

    Like David explained, you can add the directive in your .htaccess if you want the change to apply to your site only :

    Code:
    DirectoryIndex index.php index.htm index.html index.shtml index.xhtml index.wml index.perl index.pl index.plx index.ppl index.cgi index.jsp index.js index.jp index.php4 index.php3 index.phtml default.htm default.html home.htm
    If you want it to apply to all sites, please read my other post here : http://forums.cpanel.net/showpost.ph...2&postcount=10

    Don't forget that your list should look like this :
    DirectoryIndex index.php index.htm index.html index.shtml index.xhtml index.wml index.perl index.pl index.plx index.ppl index.cgi index.jsp index.js index.jp index.php4 index.php3 index.phtml default.htm default.html home.htm
    Marie - Co-Owner
    Need Further Assistance ? Here you go !
    English, french and spanish support

  6. #6
    Registered User
    Join Date
    Mar 2004
    Posts
    2

    Default

    Thanks

    John

Similar Threads

  1. Replies: 3
    Last Post: 02-21-2012, 01:34 AM
  2. want to switch hom page from index.html to index.php
    By websoftbiz in forum cPanel & WHM Discussions
    Replies: 4
    Last Post: 07-12-2008, 07:14 PM
  3. Default index.html page
    By rootuser in forum cPanel & WHM Discussions
    Replies: 4
    Last Post: 01-22-2006, 03:38 AM
  4. reseller index default page
    By plaut in forum New User Questions
    Replies: 2
    Last Post: 01-31-2005, 03:52 PM
  5. default index page
    By jimjoe in forum cPanel & WHM Discussions
    Replies: 11
    Last Post: 10-02-2003, 09:50 PM
bargain