即使index.html / php存在,如何定义apache虚拟主机以显示目录树?
You have to enabled the Indexes
option and remove the DirectoryIndex
option.
If you have AllowOverride
enabled you can add the following to your .htaccess file.
Options Indexes FollowSymLinks
DirectoryIndex disabled
If you get a welcome page, you may need to remove/edit /etc/httpd/conf.d/welcome.conf
. ON Red Hat derived OS's and others this can interfere with some directory listing.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.