web/wp-admin/options-discussion.php
branchwordpress
changeset 132 4d4862461b8d
parent 109 03b0d1493584
equal deleted inserted replaced
131:a4642baaf829 132:4d4862461b8d
    64 <?php
    64 <?php
    65 
    65 
    66 $maxdeep = (int) apply_filters( 'thread_comments_depth_max', 10 );
    66 $maxdeep = (int) apply_filters( 'thread_comments_depth_max', 10 );
    67 
    67 
    68 $thread_comments_depth = '</label><select name="thread_comments_depth" id="thread_comments_depth">';
    68 $thread_comments_depth = '</label><select name="thread_comments_depth" id="thread_comments_depth">';
    69 for ( $i = 1; $i <= $maxdeep; $i++ ) {
    69 for ( $i = 2; $i <= $maxdeep; $i++ ) {
    70 	$thread_comments_depth .= "<option value='" . esc_attr($i) . "'";
    70 	$thread_comments_depth .= "<option value='" . esc_attr($i) . "'";
    71 	if ( get_option('thread_comments_depth') == $i ) $thread_comments_depth .= " selected='selected'";
    71 	if ( get_option('thread_comments_depth') == $i ) $thread_comments_depth .= " selected='selected'";
    72 	$thread_comments_depth .= ">$i</option>";
    72 	$thread_comments_depth .= ">$i</option>";
    73 }
    73 }
    74 $thread_comments_depth .= '</select>';
    74 $thread_comments_depth .= '</select>';
    84 if ( 'newest' == get_option('default_comments_page') ) $default_comments_page .= ' selected="selected"';
    84 if ( 'newest' == get_option('default_comments_page') ) $default_comments_page .= ' selected="selected"';
    85 $default_comments_page .= '>' . __('last') . '</option><option value="oldest"';
    85 $default_comments_page .= '>' . __('last') . '</option><option value="oldest"';
    86 if ( 'oldest' == get_option('default_comments_page') ) $default_comments_page .= ' selected="selected"';
    86 if ( 'oldest' == get_option('default_comments_page') ) $default_comments_page .= ' selected="selected"';
    87 $default_comments_page .= '>' . __('first') . '</option></select>';
    87 $default_comments_page .= '>' . __('first') . '</option></select>';
    88 
    88 
    89 printf( __('Break comments into pages with %1$s comments per page and the %2$s page displayed by default'), '</label><label for="comments_per_page"><input name="comments_per_page" type="text" id="comments_per_page" value="' . esc_attr(get_option('comments_per_page')) . '" class="small-text" />', $default_comments_page );
    89 printf( __('Break comments into pages with %1$s top level comments per page and the %2$s page displayed by default'), '</label><label for="comments_per_page"><input name="comments_per_page" type="text" id="comments_per_page" value="' . esc_attr(get_option('comments_per_page')) . '" class="small-text" />', $default_comments_page );
    90 
    90 
    91 ?></label>
    91 ?></label>
    92 <br />
    92 <br />
    93 <label for="comment_order"><?php
    93 <label for="comment_order"><?php
    94 
    94