Changeset 21865
- Timestamp:
- 09/16/2012 04:16:26 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions.php
r21826 r21865 656 656 $frag = ''; 657 657 658 if ( preg_match( '|^https?://|i', $uri, $matches ) ) { 659 $protocol = $matches[0]; 660 $uri = substr( $uri, strlen( $protocol ) ); 658 if ( 0 === stripos( 'http://', $uri ) ) { 659 $protocol = 'http://'; 660 $uri = substr( $uri, 7 ); 661 } elseif ( 0 === stripos( 'https://', $uri ) ) { 662 $protocol = 'https://'; 663 $uri = substr( $uri, 8 ); 661 664 } else { 662 665 $protocol = ''; … … 672 675 $query = $parts[1]; 673 676 } 674 } elseif ( !empty( $protocol )|| strpos( $uri, '=' ) === false ) {677 } elseif ( $protocol || strpos( $uri, '=' ) === false ) { 675 678 $base = $uri . '?'; 676 679 $query = ''; … … 689 692 } 690 693 691 foreach ( (array)$qs as $k => $v ) {694 foreach ( $qs as $k => $v ) { 692 695 if ( $v === false ) 693 696 unset( $qs[$k] );
Note: See TracChangeset
for help on using the changeset viewer.