if (!is_ssl()) {
wp_redirect('https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'], 301);
exit;
}
Last active
January 29, 2020 14:26
-
-
Save jrobinsonc/1d4826bdc28bc89d316ca08763523ede to your computer and use it in GitHub Desktop.
WordPress - Redirect to HTTPS (SSL)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment