Changeset 25617
- Timestamp:
- 09/25/2013 12:46:39 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp.php
r25585 r25617 142 142 $this->did_permalink = true; 143 143 144 if ( isset($_SERVER['PATH_INFO']) ) 145 $pathinfo = $_SERVER['PATH_INFO']; 146 else 147 $pathinfo = ''; 148 $pathinfo_array = explode('?', $pathinfo); 149 $pathinfo = str_replace("%", "%25", $pathinfo_array[0]); 150 $req_uri = $_SERVER['REQUEST_URI']; 151 $req_uri_array = explode('?', $req_uri); 152 $req_uri = $req_uri_array[0]; 144 $pathinfo = isset( $_SERVER['PATH_INFO'] ) ? $_SERVER['PATH_INFO'] : ''; 145 list( $pathinfo ) = explode( '?', $pathinfo ); 146 $pathinfo = str_replace( "%", "%25", $pathinfo ); 147 148 list( $req_uri ) = explode( '?', $_SERVER['REQUEST_URI'] ); 153 149 $self = $_SERVER['PHP_SELF']; 154 $home_path = parse_url(home_url()); 155 if ( isset($home_path['path']) ) 156 $home_path = $home_path['path']; 157 else 158 $home_path = ''; 159 $home_path = trim($home_path, '/'); 150 $home_path = trim( parse_url( home_url(), PHP_URL_PATH ), '/' ); 160 151 161 152 // Trim path info from the end and the leading home path from the
Note: See TracChangeset
for help on using the changeset viewer.