WordPress 2.5 Error on Windows IIS:Undefined index: PATH_INFO
After upgrading to WordPress version 2.5 on Windows IIS,you may get the following errors:
Notice: Undefined index: PATH_INFO in (path)\wp-settings.php on line 74 Notice: Undefined index: PATH_INFO in (path)\wp-settings.php on line 77
to solve this problem,open file wp-settings.php,goto line 71 and replace the following code:
if ( $_SERVER['PATH_INFO'] == $_SERVER['SCRIPT_NAME'] ) $_SERVER['REQUEST_URI'] = $_SERVER['PATH_INFO']; else $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'] . $_SERVER['PATH_INFO'];
with:
if (empty($_SERVER['PATH_INFO'])) $_SERVER['REQUEST_URI'] = substr($_SERVER['SCRIPT_NAME'], 0, strrpos($_SERVER['SCRIPT_NAME'], '/')) . '/'; else if ( $_SERVER['PATH_INFO'] == $_SERVER['SCRIPT_NAME'] ) $_SERVER['REQUEST_URI'] = $_SERVER['PATH_INFO']; else $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'] . $_SERVER['PATH_INFO'];
this will resolve that issue,Your can also download an already modified version of wp-setting.php from here.
Related posts:
thank you, i cannot though get it to work. here is my code:
$addition = explode($path,$_SERVER['REQUEST_URI']);
and also:
$cPage = ($path == '/' ? '' : $path).$_SERVER['REQUEST_URI'];
The page with the error is here:
http://www.dnaclothing.co.za/shop/index.php/leisure/jerseys/mens-status-jersey
i appreciate your help.
go!http://www.dubozuobi.com
favorited this one, bro
[...] trying to finish a book. What I was getting were ‘undefined index’ errors; thanks to deanlee.com for the quick fix. And, of course, there were settings to change. Rereklamo kasi [...]