Apache配置URL重定向

时间:2023-03-09 22:51:37
Apache配置URL重定向

Apache配置URL重定向

修改/etc/httpd/conf/httpd.conf文件的内容

<Directory "/var/www">
AllowOverride None
# Allow open access:
Require all granted
</Directory>

<Directory "/var/www">
AllowOverride All
# Allow open access:
Require all granted
RewriteEngine On
RewriteRule /task/* /index.html?$1
</Directory>