Revert [28610] in order to avoid infinite redirect loops on reverse proxies which proxy from HTTPS to HTTP. This will be revisited at some point, possibly as an option via a filter.
Fixes #28610. Built from https://develop.svn.wordpress.org/trunk@30090 git-svn-id: http://core.svn.wordpress.org/trunk@30090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
6de35acf28
commit
9a16b52018
|
@ -360,10 +360,6 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
|
|||
else
|
||||
unset($redirect['port']);
|
||||
|
||||
if ( ! empty( $user_home['scheme'] ) && $user_home['scheme'] === 'https' ) {
|
||||
$redirect['scheme'] = 'https';
|
||||
}
|
||||
|
||||
// trailing /index.php
|
||||
$redirect['path'] = preg_replace('|/' . preg_quote( $wp_rewrite->index, '|' ) . '/*?$|', '/', $redirect['path']);
|
||||
|
||||
|
@ -421,7 +417,7 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
|
|||
( strtolower($original['host']) != 'www.' . strtolower($redirect['host']) && 'www.' . strtolower($original['host']) != strtolower($redirect['host']) ) )
|
||||
$redirect['host'] = $original['host'];
|
||||
|
||||
$compare_original = array( $original['scheme'], $original['host'], $original['path'] );
|
||||
$compare_original = array( $original['host'], $original['path'] );
|
||||
|
||||
if ( !empty( $original['port'] ) )
|
||||
$compare_original[] = $original['port'];
|
||||
|
@ -429,7 +425,7 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
|
|||
if ( !empty( $original['query'] ) )
|
||||
$compare_original[] = $original['query'];
|
||||
|
||||
$compare_redirect = array( $redirect['scheme'], $redirect['host'], $redirect['path'] );
|
||||
$compare_redirect = array( $redirect['host'], $redirect['path'] );
|
||||
|
||||
if ( !empty( $redirect['port'] ) )
|
||||
$compare_redirect[] = $redirect['port'];
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.1-alpha-30089';
|
||||
$wp_version = '4.1-alpha-30090';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue