Last active
November 16, 2023 20:54
-
-
Save pkosciak/e5434feab3d5e1282f7ff11bd6456d35 to your computer and use it in GitHub Desktop.
Resolving wp-admin redirection loop in WordPress docker setup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define('FORCE_SSL_ADMIN', true); | |
| if(!defined('WP_CLI')){ | |
| if (strpos($_SERVER['HTTP_X_FORWARDED_PROTO'], 'https') !== false){ | |
| $_SERVER['HTTPS']='on'; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment