[WordPress] 外掛分享: Force Domain Redirect

首頁外掛目錄 › Force Domain Redirect
200+
安裝啟用
★★★★
4/5 分(4 則評價)
1518 天前
最後更新
問題解決
WordPress 3.0+ v0.3 上架:2014-08-31

內容簡介

此外掛可將 http://somedomain.tld 轉址至 http://someotherdomain.tld

假設您在一個 WordPress 網站中有兩個或更多個不同的網域使用。此外掛強制使用其中一個網域,無論使用者在位址列輸入何種網域。

如果您的主機無法自動將一個網域轉址至另一個,此外掛可協助您。當使用者輸入不正確的網址時,此外掛會檢查並將其自動轉至正確網域,進行 301 轉址。

一般來說,.htaccess 應該能夠完成此任務,但我個人的經驗是無法達成此功能。這可能是因為我使用了網域別名 (alias) 或是 CNAME。我希望確保主要網域始終保持一致,即使使用過去的鏈接也是如此。

外掛標籤

開發者團隊

⬇ 下載最新版 (v0.3) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Force Domain Redirect」→ 直接安裝(推薦)

原文外掛簡介

Redirects http://somedomain.tld to http://someotherdomain.tld
Assuming you have 2 or more domains in use for a single WordPress site. This plugin forces the use of only one no matter which is entered in the address bar.
If, for some reason, your host won’t automatically redirect from one domain to another, then this plugin will do it. It checks the URL used to access the site and does a 301 redirect if incorrect.
In theory htaccess should do this, but in my case it didn’t. Perhaps because I am using domain aliases (or CNAMEs) and I wanted to insure that the main one was always in use, even when accessed using old links.

延伸相關外掛

文章
Filter
Apply Filters
Mastodon