getting index.htm to work

Discussion in 'Site & Server Administration' started by xRotorHead, Dec 30, 2006.

  1. #1
    Hello,

    Kind of new to home servers and apache, but have designed lots of web pages in the past. I now have a home server setup running the latest version of apache . Everything seems to work fine as a read-only file navigator. But I cant seem to get the "index.htm" file to launch when I navigate to that folder in the browser. For example, if you go to "http://web-address.com/music" where the music folder contains a page I designed and saved as "index.htm", the browser should pull up that index.htm page by default without having to click on anything, right? But I only seem to get a listing of the files within the "music" folder which happens to contain the "index.htm" file...then you have to click on "index.htm" in order to view that page. Thats lame...you shouldn't have to click on index.htm. Getting long winded here, but why is that? Is it something to do with the apache server thing; what do I need to do to make that index.htm trick work?
     
    xRotorHead, Dec 30, 2006 IP
  2. Futures_Equity

    Futures_Equity Well-Known Member

    Messages:
    454
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    110
    #2
    I think you need to edit htaccess file and find where says DirectoryIndex and add index.htm
     
    Futures_Equity, Dec 30, 2006 IP
  3. xRotorHead

    xRotorHead Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Beloved Futures Equity,

    You nailed it! its in the httpd.conf file. You must edit:

    <IfModule dir_module>
    DirectoryIndex index.html
    </IfModule>

    TO READ:

    <IfModule dir_module>
    DirectoryIndex index.htm
    </IfModule>

    Easy as that. Thanks for all the help.
     
    xRotorHead, Dec 30, 2006 IP