WordPress.org

Make WordPress Core

Ticket #21373: 21373.2.diff

File 21373.2.diff, 2.3 KB (added by lessbloat, 6 years ago)
  • wp-admin/options-discussion.php

     
    7171
    7272<label for="close_comments_for_old_posts">
    7373<input name="close_comments_for_old_posts" type="checkbox" id="close_comments_for_old_posts" value="1" <?php checked('1', get_option('close_comments_for_old_posts')); ?> />
    74 <?php printf( __('Automatically close comments on articles older than %s days'), '</label><input name="close_comments_days_old" type="number" min="0" step="1" id="close_comments_days_old" value="' . esc_attr(get_option('close_comments_days_old')) . '" class="small-text" />'); ?>
     74<?php _e('Automatically close comments on articles older than '); ?></label>
     75<label for="close_comments_days_old">
     76<?php printf( __('%s days'), '<input name="close_comments_days_old" type="number" min="0" step="1" id="close_comments_days_old" value="' . esc_attr(get_option('close_comments_days_old')) . '" class="small-text" />'); ?>
     77</label>
    7578<br />
    7679<label for="thread_comments">
    7780<input name="thread_comments" type="checkbox" id="thread_comments" value="1" <?php checked('1', get_option('thread_comments')); ?> />
     81<?php _e('Enable threaded (nested) comments '); ?>
     82</label>
     83<label for="thread_comments_depth">
    7884<?php
    79 
    8085$maxdeep = (int) apply_filters( 'thread_comments_depth_max', 10 );
    8186
    82 $thread_comments_depth = '</label><select name="thread_comments_depth" id="thread_comments_depth">';
     87$thread_comments_depth = '<select name="thread_comments_depth" id="thread_comments_depth">';
    8388for ( $i = 2; $i <= $maxdeep; $i++ ) {
    8489        $thread_comments_depth .= "<option value='" . esc_attr($i) . "'";
    8590        if ( get_option('thread_comments_depth') == $i ) $thread_comments_depth .= " selected='selected'";
    8691        $thread_comments_depth .= ">$i</option>";
    8792}
    88 $thread_comments_depth .= '</select>';
    89 
    90 printf( __('Enable threaded (nested) comments %s levels deep'), $thread_comments_depth );
    91 
    92 ?><br />
     93$thread_comments_depth .= '</select>';?>
     94<?php printf( __('%s levels deep'), $thread_comments_depth );?>
     95</label>
     96<br />
    9397<label for="page_comments">
    9498<input name="page_comments" type="checkbox" id="page_comments" value="1" <?php checked('1', get_option('page_comments')); ?> />
    9599<?php