Make WordPress Core


Ignore:
Timestamp:
08/30/2006 09:46:31 PM (18 years ago)
Author:
ryan
Message:

Use get_option instead of get_settings. Just 'cause.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/comment.php

    r4133 r4144  
    44    global $wpdb;
    55
    6     if (1 == get_settings('comment_moderation')) return false; // If moderation is set to manual
    7 
    8     if ( (count(explode('http:', $comment)) - 1) >= get_settings('comment_max_links') )
     6    if (1 == get_option('comment_moderation')) return false; // If moderation is set to manual
     7
     8    if ( (count(explode('http:', $comment)) - 1) >= get_option('comment_max_links') )
    99        return false; // Check # of external links
    1010
    11     $mod_keys = trim( get_settings('moderation_keys') );
     11    $mod_keys = trim( get_option('moderation_keys') );
    1212    if ( !empty($mod_keys) ) {
    1313        $words = explode("\n", $mod_keys );
     
    3434
    3535    // Comment whitelisting:
    36     if ( 1 == get_settings('comment_whitelist')) {
     36    if ( 1 == get_option('comment_whitelist')) {
    3737        if ( 'trackback' == $comment_type || 'pingback' == $comment_type ) { // check if domain is in blogroll
    3838            $uri = parse_url($url);
     
    125125function get_lastcommentmodified($timezone = 'server') {
    126126    global $cache_lastcommentmodified, $pagenow, $wpdb;
    127     $add_seconds_blog = get_settings('gmt_offset') * 3600;
     127    $add_seconds_blog = get_option('gmt_offset') * 3600;
    128128    $add_seconds_server = date('Z');
    129129    $now = current_time('mysql', 1);
     
    234234    }
    235235
    236     $mod_keys = trim( get_settings('blacklist_keys') );
     236    $mod_keys = trim( get_option('blacklist_keys') );
    237237    if ('' == $mod_keys )
    238238        return false; // If moderation keys are empty
     
    387387        $post = &get_post($commentdata['comment_post_ID']); // Don't notify if it's your own comment
    388388
    389         if ( get_settings('comments_notify') && $commentdata['comment_approved'] && $post->post_author != $commentdata['user_ID'] )
     389        if ( get_option('comments_notify') && $commentdata['comment_approved'] && $post->post_author != $commentdata['user_ID'] )
    390390            wp_notify_postauthor($comment_ID, $commentdata['comment_type']);
    391391    }
     
    617617    $excerpt = strip_tags($excerpt);
    618618    if ( function_exists('mb_strcut') ) // For international trackbacks
    619         $excerpt = mb_strcut($excerpt, 0, 252, get_settings('blog_charset')) . '...';
     619        $excerpt = mb_strcut($excerpt, 0, 252, get_option('blog_charset')) . '...';
    620620    else
    621621        $excerpt = substr($excerpt, 0, 252) . '...';
     
    636636
    637637function generic_ping($post_id = 0) {
    638     $services = get_settings('ping_sites');
     638    $services = get_option('ping_sites');
    639639    $services = preg_replace("|(\s)+|", '$1', $services); // Kill dupe lines
    640640    $services = trim($services);
     
    745745    $title = urlencode($title);
    746746    $excerpt = urlencode($excerpt);
    747     $blog_name = urlencode(get_settings('blogname'));
     747    $blog_name = urlencode(get_option('blogname'));
    748748    $tb_url = $trackback_url;
    749749    $url = urlencode(get_permalink($ID));
     
    752752    $http_request = 'POST ' . $trackback_url['path'] . ($trackback_url['query'] ? '?'.$trackback_url['query'] : '') . " HTTP/1.0\r\n";
    753753    $http_request .= 'Host: '.$trackback_url['host']."\r\n";
    754     $http_request .= 'Content-Type: application/x-www-form-urlencoded; charset='.get_settings('blog_charset')."\r\n";
     754    $http_request .= 'Content-Type: application/x-www-form-urlencoded; charset='.get_option('blog_charset')."\r\n";
    755755    $http_request .= 'Content-Length: '.strlen($query_string)."\r\n";
    756756    $http_request .= "User-Agent: WordPress/" . $wp_version;
     
    790790    $client->debug = false;
    791791    $home = trailingslashit( get_option('home') );
    792     if ( !$client->query('weblogUpdates.extendedPing', get_settings('blogname'), $home, get_bloginfo('rss2_url') ) ) // then try a normal ping
    793         $client->query('weblogUpdates.ping', get_settings('blogname'), $home);
     792    if ( !$client->query('weblogUpdates.extendedPing', get_option('blogname'), $home, get_bloginfo('rss2_url') ) ) // then try a normal ping
     793        $client->query('weblogUpdates.ping', get_option('blogname'), $home);
    794794}
    795795
Note: See TracChangeset for help on using the changeset viewer.