admin管理员组

文章数量:1425733

I want to moving my site followourtrack.fr from http to https but i have the message ERR_TOO_MANY_REDIRECTS

wp-config.php :

define('WP_HOME','/');
define('WP_SITEURL','/');

.htaccess file :

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

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
</IfModule>

I need to help

Thank you :)

I want to moving my site followourtrack.fr from http to https but i have the message ERR_TOO_MANY_REDIRECTS

wp-config.php :

define('WP_HOME','https://www.followourtrack.fr/');
define('WP_SITEURL','https://www.followourtrack.fr/');

.htaccess file :

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

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
</IfModule>

I need to help

Thank you :)

Share Improve this question edited Jun 11, 2019 at 14:02 Pratik Patel 1,1111 gold badge11 silver badges23 bronze badges asked Jun 11, 2019 at 13:12 ValentinValentin 1 1
  • Do you have any experience with WP-CLI?? – ChristopherJones Commented Jun 11, 2019 at 15:08
Add a comment  | 

3 Answers 3

Reset to default 0

First you must Update the Site Address under Settings > General. Make sure the address is https://www.followourtrack.fr/. After that update your .htaccess like below.

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
</IfModule>

That .htaccess can work with fine in my server.

Try removing the trailing slashes from the wp-config definitions, so they read:

define('WP_HOME','https://www.followourtrack.fr');
define('WP_SITEURL','https://www.followourtrack.fr');

If that fails, try removing the www from those entries:

define('WP_HOME','https://followourtrack.fr');
define('WP_SITEURL','https://followourtrack.fr');

edit your mysql database directly and change sitename and blogurl (both of which are in the wp_options table) and change them both to 'https://www.followourtrack.fr'

本文标签: Moving wordpress site from HTTP to HTTPS ERRTOOMANYREDIRECTS