Jllin

Apache主机使用.htaccess文件实现301跳转
PHP主机301设置:将以下规则添加到.htaccess文件<IfModule mod_rewrite.c&...
扫描右侧二维码阅读全文
09
2018/10

Apache主机使用.htaccess文件实现301跳转

PHP主机301设置:

将以下规则添加到.htaccess文件

<IfModule mod_rewrite.c>

RewriteEngine On

RewriteCond %{HTTP_HOST} ^mulinux.com$ [NC]

RewriteCond %{HTTP_HOST} ^mulinux.com$ [NC]

RewriteRule ^(.*)$ http://blog.mulinux.com/$1 [R=301,L]

</IfModule>

RewriteCond条件替换为自己的域名,表示将mulinux.com和mulinux.com重定向到blog.mulinux.com

Last modification:October 14th, 2018 at 10:08 am
If you think my article is useful to you, please feel free to appreciate

Leave a Comment