Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: wierd bugs


Frumph
Participant

@frumph

Found the problem with the 404 page showing up on a redirect with buddypress. It’s not buddypress.

in wp-includes/pluggable.php in the main wp core the function wp_redirect –

if ( $is_IIS ) {

header(“Refresh: 0;url=$location”);

} else {

if ( php_sapi_name() != ‘cgi-fcgi’ )

status_header($status); // This causes problems on IIS and some FastCGI setups

header(“Location: $location”);

}

the $is_IIS is doing a REFRESH: 0; url=location when on windows server 2008 header(“Location: $location”); works fine with the latest fast-cgi module release

SOO basically in wp-includes vars.php making this change:

/**

* Whether the server software is IIS or something else

* @global bool $is_IIS

*/

if (strpos($_SERVER, ‘Microsoft-IIS’)) {

if (strpos($_SERVER, ‘Microsoft-IIS/7.0’)) {

$is_IIS = false;

} else {

$is_IIS = true; // (strpos($_SERVER, ‘Microsoft-IIS’) !== false) ? true : false;

}

} else {

$is_IIS = false;

}

fixed it, by declaring that a microsoft-iis/7.0 server is *not* iis

Skip to toolbar