Make WordPress Core

Changeset 7758


Ignore:
Timestamp:
04/21/2008 05:35:57 PM (18 years ago)
Author:
ryan
Message:

Check if PATH_INFO is set to avoid undefined index errors. see #5160

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.5/wp-settings.php

    r7663 r7758  
    7070        {
    7171                // Some IIS + PHP configurations puts the script-name in the path-info (No need to append it twice)
    72                 if ( $_SERVER['PATH_INFO'] == $_SERVER['SCRIPT_NAME'] )
    73                         $_SERVER['REQUEST_URI'] = $_SERVER['PATH_INFO'];
    74                 else
    75                         $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'] . $_SERVER['PATH_INFO'];
     72                if ( isset($_SERVER['PATH_INFO']) ) {
     73                        if ( $_SERVER['PATH_INFO'] == $_SERVER['SCRIPT_NAME'] )
     74                                $_SERVER['REQUEST_URI'] = $_SERVER['PATH_INFO'];
     75                        else
     76                                $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'] . $_SERVER['PATH_INFO'];
     77                }
    7678
    7779                // Append the query string if it exists and isn't null
Note: See TracChangeset for help on using the changeset viewer.