![](/img/trans.png)
[英]Redirecting from old Drupal site to Wordpress site on same domain
[英]wordpress site domain open the old site domain
舊路
測試路徑
當我打開此URL站點時,我將完整的wordpress項目上載到了測試文件夾中,我的新wordpress站點路徑是這樣的
當我單擊打開的任何導航鏈接頁面並且網址顯示給我時
http://www.tantifilm.top/serie-tv/鏈接,而不是此http://www.tantifilm.top/test/serie-tv/
siteurl : http://www.tantifilm.top/test/
baseurl : http://www.tantifilm.top/test/
我導入數據庫並更新wp_option中的鏈接,我不明白為什么http://www.tantifilm.top/test/serie-tv/此鏈接無法打開
在您的數據庫(sql)上嘗試以下操作:
//SQL to change domain name
UPDATE wp_posts SET guid = replace(guid, 'http://www.old-domain.com','http://www.new-domain.com');
UPDATE wp_posts SET post_content = replace(post_content, 'http://www.old-domain.com', 'http://www.new-domain.com');
UPDATE wp_postmeta SET meta_value = replace(meta_value, 'http://www.old-domain.com', 'http://www.new-domain.com');
UPDATE wp_options SET option_value = replace(option_value, 'http://www.old-domain.com', 'http://www.new-domain.com') WHERE option_name = 'home' OR option_name = 'siteurl';
然后轉到WordPress后端,“設置”->“固定鏈接”,然后單擊“保存更改”。
我希望這有幫助。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.