Ticket #31405: 31405.diff
File 31405.diff, 2.5 KB (added by , 9 years ago) |
---|
-
src/wp-admin/network/upgrade.php
63 63 echo "<ul>"; 64 64 foreach ( (array) $blogs as $details ) { 65 65 switch_to_blog( $details['blog_id'] ); 66 $siteurl = site_url( );67 $upgrade_url = admin_url( 'upgrade.php?step=upgrade_db' );66 $siteurl = site_url( '', 'original' ); 67 $upgrade_url = admin_url( 'upgrade.php?step=upgrade_db', 'original' ); 68 68 restore_current_blog(); 69 69 70 70 echo "<li>$siteurl</li>"; -
src/wp-includes/link-template.php
3413 3413 * 3414 3414 * @since 3.4.0 3415 3415 * @since 4.4.0 The 'rest' scheme was added. 3416 * @since 4.6.0 The 'original' scheme was added. 3416 3417 * 3417 3418 * @param string $url Absolute URL that includes a scheme 3418 3419 * @param string|null $scheme Optional. Scheme to give $url. Currently 'http', 'https', 'login', 3419 * 'login_post', 'admin', 'relative', 'rest', 'rpc', or null. Default null.3420 * 'login_post', 'admin', 'relative', 'rest', 'rpc', 'original', or null. Default null. 3420 3421 * @return string $url URL with chosen scheme. 3421 3422 */ 3422 3423 function set_url_scheme( $url, $scheme = null ) { … … 3426 3427 $scheme = is_ssl() ? 'https' : 'http'; 3427 3428 } elseif ( $scheme === 'admin' || $scheme === 'login' || $scheme === 'login_post' || $scheme === 'rpc' ) { 3428 3429 $scheme = is_ssl() || force_ssl_admin() ? 'https' : 'http'; 3430 } elseif ( $scheme === 'original' ) { 3431 $scheme = 'https://' === substr( $url, 0, 8 ) ? 'https' : 'http'; 3429 3432 } elseif ( $scheme !== 'http' && $scheme !== 'https' && $scheme !== 'relative' ) { 3430 3433 $scheme = is_ssl() ? 'https' : 'http'; 3431 3434 } … … 3450 3453 * @param string $url The complete URL including scheme and path. 3451 3454 * @param string $scheme Scheme applied to the URL. One of 'http', 'https', or 'relative'. 3452 3455 * @param string|null $orig_scheme Scheme requested for the URL. One of 'http', 'https', 'login', 3453 * 'login_post', 'admin', 'relative', 'rest', 'rpc', or null.3456 * 'login_post', 'admin', 'relative', 'rest', 'rpc', 'original', or null. 3454 3457 */ 3455 3458 return apply_filters( 'set_url_scheme', $url, $scheme, $orig_scheme ); 3456 3459 }