WordPress.org

Make WordPress Core

Changeset 10218


Ignore:
Timestamp:
12/17/2008 05:58:31 PM (9 years ago)
Author:
ryan
Message:

is_ssl() improvements. Props johnbillion. fixes #8641 for 2.7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.7/wp-includes/functions.php

    r10150 r10218  
    28052805 */
    28062806function is_ssl() {
    2807     return ( isset($_SERVER['HTTPS']) && 'on' == strtolower($_SERVER['HTTPS']) ) ? true : false;
     2807    if ( isset($_SERVER['HTTPS']) ) {
     2808        if ( 'on' == strtolower($_SERVER['HTTPS']) )
     2809            return true;
     2810        if ( '1' == $_SERVER['HTTPS'] )
     2811            return true;
     2812    } elseif ( isset($_SERVER['SERVER_PORT']) && ( '443' == $_SERVER['SERVER_PORT'] ) ) {
     2813        return true;
     2814    }
     2815    return false;
    28082816}
    28092817
Note: See TracChangeset for help on using the changeset viewer.