@@ 2994-3000 (lines=7) @@ | ||
2991 | ||
2992 | $orig_scheme = $scheme; |
|
2993 | ||
2994 | if ( empty( $blog_id ) || !is_multisite() ) { |
|
2995 | $url = get_option( 'home' ); |
|
2996 | } else { |
|
2997 | switch_to_blog( $blog_id ); |
|
2998 | $url = get_option( 'home' ); |
|
2999 | restore_current_blog(); |
|
3000 | } |
|
3001 | ||
3002 | if ( ! in_array( $scheme, array( 'http', 'https', 'relative' ) ) ) { |
|
3003 | if ( is_ssl() && ! is_admin() && 'wp-login.php' !== $pagenow ) |
|
@@ 3064-3070 (lines=7) @@ | ||
3061 | * @return string Site URL link with optional path appended. |
|
3062 | */ |
|
3063 | function get_site_url( $blog_id = null, $path = '', $scheme = null ) { |
|
3064 | if ( empty( $blog_id ) || !is_multisite() ) { |
|
3065 | $url = get_option( 'siteurl' ); |
|
3066 | } else { |
|
3067 | switch_to_blog( $blog_id ); |
|
3068 | $url = get_option( 'siteurl' ); |
|
3069 | restore_current_blog(); |
|
3070 | } |
|
3071 | ||
3072 | $url = set_url_scheme( $url, $scheme ); |
|
3073 |