WordPress URL中的双域

问题描述 投票:1回答:2

我最近在WordPress中合并了数据库,现在我的内容在其URL中获得了多个域。

例如应该是http://www.example.com/content

但它是http://www.example.com/www.example.com/content

我的设置显示:WordPress地址(URL)http://www.example.com/网站地址(URL)http://www.example.com/

我尚未对HTACCESS进行任何更改

php wordpress .htaccess url-rewriting
2个回答
1
投票

通过硬编码

define('WP_HOME','http://www.example.com/');
define('WP_SITEURL','http://www.example.com');

进入wp-config.php,我能够解决此问题。


0
投票

按照@cool的建议,您必须在wp_options表中检查选项名称“ home”(可能也是“ siteurl”,因为您使用的名称相同)。

保存以“ http://”开头的选项。

类似于http://www.example.com。从问题中可以看到,您已将它们另存为www.example.com:

但它是http://www.example.com/www.example.com/content

© www.soinside.com 2019 - 2024. All rights reserved.