字preSS - 重定向所有页面到其他域和异常的主页和可湿性粉剂管理员 [英] WordPress - redirect all pages to other domain and exception homepage and wp-admin
问题描述
我需要使用Word preSS重定向帮助。我认为,最简单的方法就是让这个与htaccess文件。 我想301重定向从我的网站www.domain.com所有网页子域web.domain.com,但我希望有例外的主页www.domain.com,并在www.domain.com/wp字preSS管理-admin / ...和www.domain.com/wp-login.php
我有基本的单词preSS htaccess的设置:
< IfModule mod_rewrite.c>
RewriteEngine叙述上
的RewriteBase /
重写规则^指数\ .PHP $ - [L]
的RewriteCond%{} REQUEST_FILENAME!-f
的RewriteCond%{} REQUEST_FILENAME!-d
重写规则。的index.php [L]
< / IfModule>
感谢您的帮助 - 我发现,我需要两个WP管理员,所以我使这个设置:
RewriteEngine叙述上
的RewriteCond%{REQUEST_URI}!/ $
的RewriteCond%{REQUEST_URI}!/ wpinstall(/.*)$
重写规则(。*)http://web.domain.cz/$1 [R = 301,QSA]
和我安装可湿性粉剂到子文件夹wpinstall
I need help with WordPress redirect. I think, that the simplest way is make this with htaccess file. I want 301 redirect all pages from my site www.domain.com to subdomain web.domain.com, but I want have exception for homepage www.domain.com and for wordpress admin in www.domain.com/wp-admin/... and www.domain.com/wp-login.php
I have the basic wordpress htaccess settings:
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
Thanks for your help - I find, that I need both wp admin so I make this settings:
RewriteEngine on
RewriteCond %{REQUEST_URI} !/$
RewriteCond %{REQUEST_URI} !/wpinstall(/.*)$
RewriteRule (.*) http://web.domain.cz/$1 [R=301,QSA]
And I install wp to subfolder wpinstall
这篇关于字preSS - 重定向所有页面到其他域和异常的主页和可湿性粉剂管理员的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!