Fix for people who move.

git-svn-id: http://svn.automattic.com/wordpress/trunk@1526 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
saxmatt 2004-08-09 09:29:25 +00:00
parent c6cd1024c3
commit 9fe8ff24e2
1 changed files with 4 additions and 0 deletions

View File

@ -37,6 +37,10 @@ for ($i = 0; $i < count($wpvarstoreset); $i = $i + 1) {
}
}
// 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']) );
switch($action) {
case 'logout':