Rewrite Rules: Ensure `url_to_postid()` operates as expected when it's used in the context of another site within a Multisite network that uses mixed URL schemes.
Fixes #35531 Built from https://develop.svn.wordpress.org/trunk@36750 git-svn-id: http://core.svn.wordpress.org/trunk@36717 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
5edba14d1a
commit
f7101e6cbf
|
@ -487,7 +487,8 @@ function url_to_postid( $url ) {
|
||||||
$url = $url_split[0];
|
$url = $url_split[0];
|
||||||
|
|
||||||
// Set the correct URL scheme.
|
// Set the correct URL scheme.
|
||||||
$url = set_url_scheme( $url );
|
$scheme = parse_url( home_url(), PHP_URL_SCHEME );
|
||||||
|
$url = set_url_scheme( $url, $scheme );
|
||||||
|
|
||||||
// Add 'www.' if it is absent and should be there
|
// Add 'www.' if it is absent and should be there
|
||||||
if ( false !== strpos(home_url(), '://www.') && false === strpos($url, '://www.') )
|
if ( false !== strpos(home_url(), '://www.') && false === strpos($url, '://www.') )
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.5-beta1-36749';
|
$wp_version = '4.5-beta1-36750';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue