The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

directory indexing help

Discussion in 'General Discussion' started by butch, Aug 13, 2003.

  1. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    I have directory indexing off by default server-wide.

    When put a .htaccess file in a directory that I want to show the contents in, I get the "Index of /folder" title but none of the files get listed.

    Is there a setting that I missed somewhere?

    cPanel.net Support Ticket Number:
     
  2. ciphervendor

    ciphervendor Well-Known Member

    Joined:
    Aug 26, 2002
    Messages:
    1,052
    Likes Received:
    0
    Trophy Points:
    36
    contents of the .htaccess file should be:

    Options +Indexes

    cPanel.net Support Ticket Number:
     
  3. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    That is what I put in the .htaccess.

    cPanel.net Support Ticket Number:
     
  4. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Check the permissions on the directory.
     
  5. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    The permission for that folder is the default 755.

    Should it be something else?

    cPanel.net Support Ticket Number:
     
  6. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    You may need to check the permissions on the directory one up and so on to see if any of them is forbidding others to read the contents.
     
  7. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    folder permissions look good.

    Any other suggestions?

    cPanel.net Support Ticket Number:
     
  8. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Have you tried the index manager in cpanel to see if it makes any difference?
     
  9. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    Yup.

    I tried the index manager as well as creating the .htaccess file myself.

    cPanel.net Support Ticket Number:
     
  10. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Are you able to see the contents if you set up an .htaccess in another folder on this user or another user's space?
     
  11. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    Good question.

    It looks like it is a server wide issue as I cannot get it to work on any account.

    Nothing has been changed in the access.conf and httpd.conf as far as changing the default values for anything Options related.

    cPanel.net Support Ticket Number:
     
  12. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Are you getting "Index of /folder" with an empty listing in all of them or the 403 "forbidden" message?
     
  13. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    Index of /folder on all 3 of the folders that I tried on.

    3 different accounts, 3 different folders.

    My .htaccess:

    Options +Indexes

    cPanel.net Support Ticket Number:
     
  14. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Have you got this in access.conf?

    <Directory />
    Options -Indexes .........................
    AllowOverride All
    order allow,deny
    allow from all
    </Directory>


    and this in httpd.conf?

    <Directory />
    Options All
    AllowOverride All
    </Directory>
     
  15. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    This is my access.conf:

    <Directory />
    Options Indexes FollowSymLinks ExecCGI Includes
    AllowOverride All
    order allow,deny
    allow from all
    </Directory>

    And my httpd.conf:

    <Directory />
    IndexIgnore *
    Options All
    AllowOverride All
    </Directory>

    cPanel.net Support Ticket Number:
     
  16. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Try removing this line from httpd.conf and restart apache (httpd restart):

    IndexIgnore *

    Are the folder listings now showing up?
     
  17. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    6
    I soon as I pasted the clip from my httpd.conf, I realized that the IndexIgnore was what was causing it.

    Thanks for helping me out goodmove!

    cPanel.net Support Ticket Number:
     
  18. goodmove

    goodmove Well-Known Member

    Joined:
    May 12, 2003
    Messages:
    624
    Likes Received:
    0
    Trophy Points:
    16
    Glad it's resolved. :)

    Yes, IndexIgnore hides the directory contents. It's very useful in some other ways, such as for hiding certain file extensions or file names in the folder lists. Eg:
    Code:
    IndexIgnore *.php *.phps *.php4 .ht* *.sht* robots.txt
     
Loading...

Share This Page