Questions? Feedback? powered by Olark live chat software
Knowledgebase
Author Avatar

Wordpress on 80 port behind HTTPS terminating proxy

Written by: on 02 April 2020 12:34 PM 02 April 2020 12:34 PM

If you run Wordpress on HTTP-only host or instance which is behind HTTPS proxy it is highly possible you will get infinite redirect loop to HTTPS.

To fix that you need to modify the file wp-config.php and add following lines:

 

if($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https'){

$_SERVER['HTTPS'] = 'on';

$_SERVER['SERVER_PORT'] = 443; }

(0 vote(s))
Helpful
Not helpful

Comments (0)