Changeset 13881 for trunk/wp-includes/link-template.php
- Timestamp:
- 03/29/2010 07:57:17 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/link-template.php
r13880 r13881 2035 2035 */ 2036 2036 function network_site_url( $path = '', $scheme = null ) { 2037 global $current_site; 2037 2038 $orig_scheme = $scheme; 2038 2039 if ( !in_array($scheme, array('http', 'https')) ) { … … 2052 2053 2053 2054 if ( !empty($path) && is_string($path) && strpos($path, '..') === false ) 2054 $url .= '/' .ltrim($path, '/');2055 $url .= ltrim($path, '/'); 2055 2056 2056 2057 return apply_filters('network_site_url', $url, $path, $orig_scheme); … … 2072 2073 */ 2073 2074 function network_home_url( $path = '', $scheme = null ) { 2075 global $current_site; 2074 2076 $orig_scheme = $scheme; 2075 2077 $scheme = is_ssl() && !is_admin() ? 'https' : 'http'; … … 2077 2079 $url = 'http://' . $current_site->domain . $current_site->path; 2078 2080 2079 $url = str_replace( 'http://', "$scheme://", $ home);2081 $url = str_replace( 'http://', "$scheme://", $url ); 2080 2082 2081 2083 if ( !empty( $path ) && is_string( $path ) && strpos( $path, '..' ) === false ) 2082 $url .= '/' .ltrim( $path, '/' );2084 $url .= ltrim( $path, '/' ); 2083 2085 2084 2086 return apply_filters( 'network_home_url', $url, $path, $orig_scheme); … … 2096 2098 */ 2097 2099 function network_admin_url( $path = '', $scheme = 'admin' ) { 2098 $url = network_site_url( $blog_id,'wp-admin/', $scheme);2100 $url = network_site_url('wp-admin/', $scheme); 2099 2101 2100 2102 if ( !empty($path) && is_string($path) && strpos($path, '..') === false )
Note: See TracChangeset
for help on using the changeset viewer.