当我访问localhost/mypage.php时,=>工作
当我访问localhost/mypage时,=>不工作
# /usr/local/etc/apache/2.4/extra/httpd-vhosts.conf
<VirtualHost *:80>
ServerName localhost
Redirect permanent / https://localhost/
</VirtualHost>
<VirtualHost *:443>
ServerName localhost
DocumentRoot "/Users/myuser/Documents/mywebsite/httpdocs"
DirectoryIndex index.php
<Directory "/Users/myuser/Documents/mywebsite/httpdocs">
Options +FollowSymLinks +MultiViews -Indexes
AllowOverride all
Require all granted
</Directory>
SSLProtocol -all +TLSv1.2
SSLHonorCipherOrder On
SSLCipherSuite HIGH:MEDIUM:!MD5:!RC4:!3DES
SSLCertificateFile /usr/local/etc/apache2/2.4/ssl/localhost.crt
SSLCertificateKeyFile /usr/local/etc/apache2/2.4/ssl/server.key
</VirtualHost>在选项行中,我尝试了以下几点:
发布于 2017-01-25 21:46:34
显然,MultiViews依赖于协商模块。
Mac的安装Apache与下面的模块默认注释掉!!
# LoadModule negotiation_module libexec/mod_negotiation.so我只需取消注释并重新加载Apache。现在起作用了!
https://serverfault.com/questions/828622
复制相似问题