How to show content (files) in directory in browser?


To enable directory listings for a folder on your web site:

- If a directory doesn't contain an index file (index.html, index.htm, index.php, etc) then you get an error message

- If you want them to see all the files in a directory, create an .htaccess file in the directory, containing this one line:

Options +Indexes

- Then remove any index files and the directory will display all files

More options:

Options +Indexes
IndexOptions FancyIndexing FoldersFirst NameWidth=* DescriptionWidth=*

Options +Indexes
IndexOptions FancyIndexing FoldersFirst NameWidth=30 DescriptionWidth=30

Options +Indexes
IndexOptions FancyIndexing FoldersFirst SuppressIcon

 

Ref:

https://www.virtualmin.com/node/31112

 



Article ID: 65
Created On: Fri, Feb 5, 2021 at 12:53 PM
Last Updated On: Fri, Feb 5, 2021 at 12:53 PM
Authored by: Saeed Nobakht [[email protected]]

Online URL: https://www.navel.ir/article/how-to-show-content-files-in-directory-in-browser-65.html