简体   繁体   中英

Some of wordpress posts getting err_too_many_redirects

when ı checked my wordpress https website today i found some redirecting errors.

I never created those redirection on my side.

  1. https://www.estambul.net/sitios-de-interes/mezquita-azul/
  2. https://www.estambul.net/sitios-de-interes/santa-sofia/

these two posts redirected to

****/sitios-de-interes/museo-arqueologico-de-estambul/

and this

****/sitios-de-interes/museo-arqueologico-de-estambul/

redirected to

****/sitios-de-interes/santa-sofia/

all these creates an infinite loop.

here you can see my htaccess

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{HTTPS} !=on [NC]
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
<IfModule mod_headers.c>
Header always set Strict-Transport-Security 'max-age=31536000' env=HTTPS
</IfModule>
# END rlrssslReallySimpleSSL
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

Where it comes this problem please help.

Other posts doesnt have the same problem.

如果有任何脚本导致此重定向,请检查这些帖子的内容。

After two days of working we have solved the issue by removing old slugs of these posts from postmeta in mysql.

Old slugs were saved with wrong post ids. That was the problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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