Make WordPress Core

Changeset 16907


Ignore:
Timestamp:
12/14/2010 10:15:31 AM (14 years ago)
Author:
dd32
Message:

Restore pre-3.1 "Status:" header handling for IIS in wp_redirect. Revist in 3.2 to see if it's still required. Fixes #10187

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/pluggable.php

    r16760 r16907  
    877877 */
    878878function wp_redirect($location, $status = 302) {
     879    global $is_IIS;
     880
    879881    $location = apply_filters('wp_redirect', $location, $status);
    880882    $status = apply_filters('wp_redirect_status', $status, $location);
     
    885887    $location = wp_sanitize_redirect($location);
    886888
    887     if ( php_sapi_name() != 'cgi-fcgi' )
     889    if ( !$is_IIS && php_sapi_name() != 'cgi-fcgi' )
    888890        status_header($status); // This causes problems on IIS and some FastCGI setups
     891
    889892    header("Location: $location", true, $status);
    890893}
Note: See TracChangeset for help on using the changeset viewer.