wampserver的Apache 2.4.9配置SSL不工作
问题描述:
我跟着https://madurad.wordpress.com/2014/04/25/redirect-http-to-https-with-wamp-server/设置SSL在我wampserver.When我测试配置,我得到了一个错误:wampserver的Apache 2.4.9配置SSL不工作
C:\wamp\bin\apache\apache2.4.9\bin>httpd -t
AH00526: Syntax error on line 213 of C:/wamp/bin/apache/apache2.4.9/conf/extra/h
ttpd-ssl.conf:
Invalid command 'Override', perhaps misspelled or defined by a module not includ
ed in the server configuration
有我的配置在部分213行,这是目录.... /目录配置。
<Directory "C:/wamp/www/">
Options Indexes FollowSymLinks MultiViews
Override All
Order allow,deny
allow from all
SSLOptions +StdEnvVars
</Directory>
我该如何解决这个错误?
答
没有override
参数!
我想你的意思是AllowOverride
所以尽量
<Directory "C:/wamp/www/">
Options Indexes FollowSymLinks MultiViews
AllowOverride All <-- fix1
Order allow,deny
allow from all
SSLOptions +StdEnvVars
</Directory>
另外的Apache 2.4改变了Order...
和Allow ...
的语法Require ...
所以语法应该是
<Directory "C:/wamp/www/">
Options Indexes FollowSymLinks MultiViews
AllowOverride All <-- fix1
Require all granted <-- fix2
SSLOptions +StdEnvVars
</Directory>