我有 19 个重定向,但我似乎找不到它们-WordPress

I have 19 redirects but I can't seem to find them-Wordpress

我的主页上存在无限循环重定向问题。该消息出现在所有浏览器中。我尝试删除缓存和 cookie,并上传了新的 .htaccess 和 sitemap.xml,但没有任何变化。

然后我使用了一个重定向检查工具,它显示我有 19 个重定向,但我不知道它们设置在哪里。我在 cpanel 中检查了重定向,但那里有 none。插件没有问题。我不知道发生了什么。有什么建议吗?

你可以检查几件事

  1. 检查 wp-config 并尝试显式设置站点 url

    define('WP_HOME','http://yourdomain.com');
    define('WP_SITEURL','http://yourdomain.com');
    
  2. 如果出现同样的问题,请禁用所有插件并尝试访问该网站

  3. 检查 .htaccess 规则(如果有)。将 htaccess 替换为以下内容(先备份现有的)

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>