diff --git src/wp-includes/functions.php src/wp-includes/functions.php
index 58a098f916..cbd17d211d 100644
|
|
|
function wp_guess_url() { |
| 5513 | 5513 | $directory = str_replace( ABSPATH, '', $script_filename_dir ); |
| 5514 | 5514 | // Strip off the subdirectory, and any file/query params. |
| 5515 | 5515 | $path = preg_replace( '#/' . preg_quote( $directory, '#' ) . '/[^/]*$#i', '', $_SERVER['REQUEST_URI'] ); |
| 5516 | | } elseif ( false !== strpos( $abspath_fix, $script_filename_dir ) ) { |
| | 5516 | } elseif ( '' !== $script_filename_dir && false !== strpos( $abspath_fix, $script_filename_dir ) ) { |
| 5517 | 5517 | // Request is hitting a file above ABSPATH. |
| 5518 | 5518 | $subdirectory = substr( $abspath_fix, strpos( $abspath_fix, $script_filename_dir ) + strlen( $script_filename_dir ) ); |
| 5519 | 5519 | // Strip off any file/query params from the path, appending the subdirectory to the installation. |