1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Urgent Wordpress help needed...showing directory contents not index.php????

Discussion in 'BlackHat Lounge' started by tb303, Oct 31, 2016.

  1. tb303

    tb303 Power Member

    Joined:
    Dec 18, 2011
    Messages:
    734
    Likes Received:
    388
    Got a problem with a site only showing directory contents even though the index.php file is there.

    if i load root/index.php it just shows the directory contents again
    if i load root/wp-admin/ it just shows directory contents
    if i load root/wp-admin/index.php i shows the login page, but after successful login its back to root/wp-admin/ which shows directory again.

    I can log into the site and tried putting it into maintenance mode but that makes no difference.

    Im thinking its a server config problem but not sure whats changed to cause this or where to look.
    I have sent a support ticket to the hosts but hoping BHW can help me fix this while I wait?

    edit: sorry wrong section - was meant for the lounge but i rushed.
     
  2. Asif WILSON Khan

    Asif WILSON Khan Executive VIP Jr. VIP

    Joined:
    Nov 10, 2012
    Messages:
    11,445
    Likes Received:
    32,352
    Gender:
    Male
    Occupation:
    Fun Lovin' Criminal
    Location:
    London
    Home Page:
    Is this a new installation?
    Have you tried re-installing WP? If you can get into WP Admin try downloading WP again.
     
    • Thanks Thanks x 1
  3. tb303

    tb303 Power Member

    Joined:
    Dec 18, 2011
    Messages:
    734
    Likes Received:
    388
    Panic over! Cheers for for quick reply I found the problem.

    If anybody else runs into this it was caused by a .htaccess file in a parent directory containing the following line
    Code:
    DirectoryIndex index.html
    This was being inherited by the sites directory so i just added this to the broken sites .htaccess
    Code:
    DirectoryIndex index.php index.html /index.php
    But installing wordfence is a better solution probably.

    I just had an angry call from an offline business sent me into panic mode a bit lol