Skip to content

Apache 301重定向

Apache

@重定向到www

apache
RewriteEngine On
RewriteCond %{HTTP_HOST} ^ioiox.com [NC]
RewriteRule ^(.*)$ https://www.ioiox.com/$1 [L,R=301]

www重定向到@

apache
RewriteEngine On
RewriteCond %{HTTP_HOST} !^ioiox.com$ [NC]
RewriteRule ^(.*)$ https://ioiox.com/$1 [L,R=301]