Make WordPress Core


Ignore:
Timestamp:
01/26/2010 08:42:37 PM (17 years ago)
Author:
ryan
Message:

Remove first page and first comment filters. They're no longer needed. see #11644

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/upgrade.php

    r12784 r12854  
    194194
    195195        // Default comment
     196        $first_comment_author = __('Mr WordPress');
     197        $first_comment_url = 'http://wordpress.org/';
     198        $first_comment = __('Hi, this is a comment.<br />To delete a comment, just log in and view the post&#039;s comments. There you will have the option to edit or delete them.');
    196199        if ( is_multisite() ) {
    197                 $first_comment_author = get_site_option( 'first_comment_author' );
    198                 $first_comment_url = get_site_option( 'first_comment_url' );
    199                 $first_comment = get_site_option( 'first_comment' );
    200         } else {
    201                 $first_comment_author = __('Mr WordPress');
    202                 $first_comment_url = 'http://wordpress.org/';
    203                 $first_comment = __('Hi, this is a comment.<br />To delete a comment, just log in and view the post&#039;s comments. There you will have the option to edit or delete them.');
    204         }       
     200                $first_comment_author = get_site_option( 'first_comment_author', $first_comment_author );
     201                $first_comment_url = get_site_option( 'first_comment_url', 'http://' . $current_site->domain . $current_site->path );
     202                $first_comment = get_site_option( 'first_comment', $first_comment );
     203        }
    205204        $wpdb->insert( $wpdb->comments, array(
    206205                                                                'comment_post_ID' => 1,
    207206                                                                'comment_author' => $first_comment_author,
    208207                                                                'comment_author_email' => '',
    209                                                                 'comment_author_url' => 'http://wordpress.org/',
     208                                                                'comment_author_url' => $first_comment_url,
    210209                                                                'comment_date' => $now,
    211210                                                                'comment_date_gmt' => $now_gmt,
    … …  
    214213
    215214        // First Page
    216         if ( is_multisite() && get_site_option( 'first_page' ) )
    217                 $first_page = get_site_option( 'first_page' );
    218         else
    219                 $first_page = __('This is an example of a WordPress page, you could edit this to put information about yourself or your site so readers know where you are coming from. You can create as many pages like this one or sub-pages as you like and manage all of your content inside of WordPress.');
     215        $first_page = __('This is an example of a WordPress page, you could edit this to put information about yourself or your site so readers know where you are coming from. You can create as many pages like this one or sub-pages as you like and manage all of your content inside of WordPress.');
     216        if ( is_multisite() )
     217                $first_page = get_site_option( 'first_page', $first_page );
    220218        $first_post_guid = get_option('home') . '/?page_id=2';
    221219        $wpdb->insert( $wpdb->posts, array(
Note: See TracChangeset for help on using the changeset viewer.