Disable directory listing on apache; but access to individual files should be allowed

前端 未结 5 1862
夕颜
夕颜 2021-01-31 19:28

I do not want to use .htaccess. How should I change my Directory attributes?


   ServerName abc.com
   DocumentRoot /usr/share/uploads
           


        
5条回答
  •  攒了一身酷
    2021-01-31 19:45

    I really couldnt find a direct answer on internet ; even on apache documentation. Finally, could find the solution through few iterations; we need to use Options and the value should NOT contain Indexes.

    
            Options Includes FollowSymLinks MultiViews
            AllowOverride None
             Order allow,deny
          Allow from all
       
    

提交回复
热议问题