Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Can I change one directory to look for index.php before .html?

Discussion in 'General Discussion' started by noimad1, May 28, 2004.

  1. noimad1

    noimad1 Well-Known Member

    Joined:
    Mar 27, 2003
    Messages:
    627
    Likes Received:
    0
    Trophy Points:
    166
    I need to change one directory on my server to look for index.php file and run it as default. There is also an index.html file in the directory, but I don't want this one to go first.

    Is there a way I can do that per directory?

    Thanks,
    Damion
     
  2. darksoul

    darksoul Active Member

    Joined:
    Feb 20, 2003
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    156
    Create an .htaccess file in that directory and add:
    DirectoryIndex index.php index.html
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. noimad1

    noimad1 Well-Known Member

    Joined:
    Mar 27, 2003
    Messages:
    627
    Likes Received:
    0
    Trophy Points:
    166
    Thanks!
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice