From 0563f1101c5c0ecb1b9773cf7495a3801728a3cd Mon Sep 17 00:00:00 2001 From: saxmatt Date: Sat, 4 Dec 2004 00:18:01 +0000 Subject: [PATCH] Don't take parts of the URI after the script name when updating the siteurl. git-svn-id: http://svn.automattic.com/wordpress/trunk@1911 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-login.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-login.php b/wp-login.php index 5623c8c5cb..fbb563fc25 100644 --- a/wp-login.php +++ b/wp-login.php @@ -45,8 +45,8 @@ header('Cache-Control: no-cache, must-revalidate'); header('Pragma: no-cache'); // If someone has moved WordPress let's try to detect it -if ( dirname('http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']) != get_settings('siteurl') ) - update_option('siteurl', dirname('http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']) ); +if ( dirname('http://' . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME']) != get_settings('siteurl') ) + update_option('siteurl', dirname('http://' . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME']) ); switch($action) {