一劳永逸apache配置

一劳永逸apache配置

<VirtualHost *:80>

DocumentRoot "D:/wamp/www"
ServerName www.example.com
ServerAlias *
<IfModule rewrite_module>
rewriteengine on
rewritecond %{HTTP_HOST} !^www\.example\.com$
rewriterule ^(.+) /%{HTTP_HOST}$1
</IfModule>
    ErrorLog "logs/www.example.com-error.log"
    CustomLog "logs/www.example.com-access.log" common
</VirtualHost>

你可能感兴趣的:(一劳永逸apache配置)