Make WordPress Core

Changeset 6203


Ignore:
Timestamp:
10/08/2007 08:48:29 PM (19 years ago)
Author:
markjaquith
Message:

Check for ORIG_PATH_INFO on IIS. props brh, fixes #5160

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-settings.php

    r6198 r6203  
    3939        else {
    4040                // If root then simulate that no script-name was specified
    41                 if (empty($_SERVER['PATH_INFO']))
    42                         $_SERVER['REQUEST_URI'] = substr($_SERVER['SCRIPT_NAME'], 0, strrpos($_SERVER['SCRIPT_NAME'], '/')) . '/';
     41                if (empty($_SERVER['PATH_INFO'])) {
     42                        if (isset($_SERVER['ORIG_PATH_INFO']))
     43                                $_SERVER['REQUEST_URI'] = $_SERVER['ORIG_PATH_INFO'];
     44                        else
     45                                $_SERVER['REQUEST_URI'] = substr($_SERVER['SCRIPT_NAME'], 0, strrpos($_SERVER['SCRIPT_NAME'], '/')) . '/';
     46    }
    4347                elseif ( $_SERVER['PATH_INFO'] == $_SERVER['SCRIPT_NAME'] )
    4448                        // Some IIS + PHP configurations puts the script-name in the path-info (No need to append it twice)
Note: See TracChangeset for help on using the changeset viewer.