简体   繁体   English

停车域重定向到登陆页面wordpress htaccess

[英]Parking domains redirect to landing page wordpress htaccess

I hope everyone doing great, I need help, I use Wordpress last version, I need define for my web site my principal default domain example MyWordpressSite.com and all parking domains go to MyWordpressSite.com/LandingPage/ any way to define all domains in one single line and redirect to the LandingPage? 我希望每个人都做得很好,我需要帮助,我使用Wordpress上一版本,我需要为我的网站定义我的主要默认域名示例MyWordpressSite.com和所有停车域转到MyWordpressSite.com/LandingPage/以任何方式定义所有域名一行并重定向到LandingPage? I dont want define domain by domain any way in htaccess or other options? 我不想在htaccess或其他选项中以域的方式定义域名?

Thanks in advances for any help! 感谢任何帮助!

Regards Manny 问候曼尼

You need a negative pattern, assuming you're on Apache: 你需要一个负面的模式,假设你在Apache上:

RewriteEngine on
#usually need next line though modify if WordPress is running in a subfolder
RewriteBase /
RewriteCond %{HTTP_HOST} !^your\.domain\.tld$
RewriteRule ^ http://your.domain.tld/landing-page/ [L,R=301]

Any request to your non-primary domain will be permanently redirected to that page. 对您的非主域的任何请求都将被永久重定向到该页面。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM