Make WordPress Core


Ignore:
Timestamp:
07/15/2008 02:01:08 AM (17 years ago)
Author:
mdawaffe
Message:

crazyhorse: merge with log:trunk@8240:8334

File:
1 edited

Legend:

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

    r8242 r8335  
    491491    $newvalue = sanitize_option( $option_name, $newvalue );
    492492
     493    $oldvalue = get_option( $safe_option_name );
     494
     495    $newvalue = apply_filters( 'pre_update_option_' . $option_name, $newvalue, $oldvalue );
     496
    493497    // If the new and old values are the same, no need to update.
    494     $oldvalue = get_option( $safe_option_name );
    495498    if ( $newvalue === $oldvalue )
    496499        return false;
     
    14931496        $url = trailingslashit( $siteurl ) . UPLOADS;
    14941497    }
    1495    
     1498
     1499    $bdir = $dir;
     1500    $burl = $url;
     1501
    14961502    $subdir = '';
    14971503    if ( get_option( 'uploads_use_yearmonth_folders' ) ) {
     
    15131519    }
    15141520
    1515     $uploads = array( 'path' => $dir, 'url' => $url, 'subdir' => $subdir, 'error' => false );
     1521    $uploads = array( 'path' => $dir, 'url' => $url, 'subdir' => $subdir, 'basedir' => $bdir, 'baseurl' => $burl, 'error' => false );
    15161522    return apply_filters( 'upload_dir', $uploads );
    15171523}
     
    22542260 */
    22552261function is_ssl() {
    2256     return ( 'on' == strtolower($_SERVER['HTTPS']) ) ? true : false;
     2262    return ( isset($_SERVER['HTTPS']) && 'on' == strtolower($_SERVER['HTTPS']) ) ? true : false;
    22572263}
    22582264
Note: See TracChangeset for help on using the changeset viewer.