Make WordPress Core


Ignore:
Timestamp:
09/12/2013 06:56:20 AM (10 years ago)
Author:
dd32
Message:

Fix wp_guess_url() to work in every scenario I could find, allows us to use it to determine the correct path to the WordPress Site URL before installation for install.php and setup-config.php redirects. Fixes #24480 Fixes #16884

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/setup-config.php

    r25173 r25396  
    5555// Turn register_globals off.
    5656wp_unregister_GLOBALS();
     57
     58// Standardize $_SERVER variables across setups.
     59wp_fix_server_vars();
    5760
    5861require_once(ABSPATH . WPINC . '/compat.php');
     
    199202        require_once( ABSPATH . WPINC . '/class-http.php' );
    200203        require_once( ABSPATH . WPINC . '/http.php' );
    201         wp_fix_server_vars();
    202204        /**#@+
    203205         * @ignore
    204206         */
    205207        function get_bloginfo() {
    206             return ( ( is_ssl() ? 'https://' : 'http://' ) . $_SERVER['HTTP_HOST'] . str_replace( $_SERVER['PHP_SELF'], '/wp-admin/setup-config.php', '' ) );
     208            return wp_guess_url();
    207209        }
    208210        /**#@-*/
Note: See TracChangeset for help on using the changeset viewer.