WordPress.org

Make WordPress Core

Changeset 30090


Ignore:
Timestamp:
10/29/2014 06:36:41 PM (5 years ago)
Author:
johnbillion
Message:

Revert [28610] in order to avoid infinite redirect loops on reverse proxies which proxy from HTTPS to HTTP. This will be revisited at some point, possibly as an option via a filter.

Fixes #28610.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/canonical.php

    r29901 r30090  
    361361        unset($redirect['port']);
    362362
    363     if ( ! empty( $user_home['scheme'] ) && $user_home['scheme'] === 'https' ) {
    364         $redirect['scheme'] = 'https';
    365     }
    366 
    367363    // trailing /index.php
    368364    $redirect['path'] = preg_replace('|/' . preg_quote( $wp_rewrite->index, '|' ) . '/*?$|', '/', $redirect['path']);
     
    422418        $redirect['host'] = $original['host'];
    423419
    424     $compare_original = array( $original['scheme'], $original['host'], $original['path'] );
     420    $compare_original = array( $original['host'], $original['path'] );
    425421
    426422    if ( !empty( $original['port'] ) )
     
    430426        $compare_original[] = $original['query'];
    431427
    432     $compare_redirect = array( $redirect['scheme'], $redirect['host'], $redirect['path'] );
     428    $compare_redirect = array( $redirect['host'], $redirect['path'] );
    433429
    434430    if ( !empty( $redirect['port'] ) )
Note: See TracChangeset for help on using the changeset viewer.