Skip to:
Content

bbPress.org

Ticket #2632: 2632.diff

File 2632.diff, 9.2 KB (added by netweb, 9 years ago)
  • src/includes/admin/metaboxes.php

     
    2828                $text       = sprintf( _n( '%d Forum', '%d Forums', $r['forum_count'], 'bbpress' ), $r['forum_count'] );
    2929                $elements[] = '<a href="' . esc_url( $link ) . '" class="bbp-glance-forums">' . esc_html( $text ) . '</a>';
    3030        }
    31        
     31
    3232        // Topics
    3333        if ( current_user_can( 'publish_topics' ) ) {
    3434                $link       = add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), get_admin_url( null, 'edit.php' ) );
     
    343343
    344344        <p>
    345345                <strong class="label"><?php esc_html_e( 'Parent:', 'bbpress' ); ?></strong>
    346                 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Forum Parent', 'bbpress' ); ?></label>
     346                <label class="screen-reader-text" for="bbp_forum_parent_id_select"><?php esc_html_e( 'Forum Parent', 'bbpress' ); ?></label>
    347347                <?php bbp_dropdown( array(
    348348                        'post_type'          => bbp_get_forum_post_type(),
    349349                        'selected'           => $post_parent,
     
    354354                        'exclude'            => $post_id,
    355355
    356356                        // Output-related
    357                         'select_id'          => 'parent_id',
     357                        'select_id'          => 'bbp_forum_parent_id_select',
    358358                        'tab'                => bbp_get_tab_index(),
    359359                        'options_only'       => false,
    360360                        'show_none'          => __( '&mdash; No parent &mdash;', 'bbpress' ),
     
    399399
    400400        <p>
    401401                <strong class="label"><?php esc_html_e( 'Type:', 'bbpress' ); ?></strong>
    402                 <label class="screen-reader-text" for="bbp_stick_topic"><?php esc_html_e( 'Topic Type', 'bbpress' ); ?></label>
     402                <label class="screen-reader-text" for="bbp_stick_topic_select"><?php esc_html_e( 'Topic Type', 'bbpress' ); ?></label>
    403403                <?php bbp_form_topic_type_dropdown( array( 'topic_id' => $post_id ) ); ?>
    404404        </p>
    405405
     
    411411
    412412        <p>
    413413                <strong class="label"><?php esc_html_e( 'Status:', 'bbpress' ); ?></strong>
    414                 <label class="screen-reader-text" for="bbp_open_close_topic"><?php esc_html_e( 'Select whether to open or close the topic.', 'bbpress' ); ?></label>
    415                 <?php bbp_form_topic_status_dropdown( array( 'select_id' => 'post_status', 'topic_id' => $post_id ) ); ?>
     414                <label class="screen-reader-text" for="bbp_topic_status_select"><?php esc_html_e( 'Select what status to give the topic.', 'bbpress' ); ?></label>
     415                <?php bbp_form_topic_status_dropdown( array( 'topic_id' => $post_id ) ); ?>
    416416        </p>
    417417
    418418        <?php
     
    425425
    426426        <p>
    427427                <strong class="label"><?php esc_html_e( 'Forum:', 'bbpress' ); ?></strong>
    428                 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label>
     428                <label class="screen-reader-text" for="bbp_topic_forum_select"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label>
    429429                <?php bbp_dropdown( array(
    430430                        'post_type'          => bbp_get_forum_post_type(),
    431431                        'selected'           => bbp_get_topic_forum_id( $post_id ),
     
    436436                        'exclude'            => '',
    437437
    438438                        // Output-related
    439                         'select_id'          => 'parent_id',
     439                        'select_id'          => 'bbp_topic_forum_select',
    440440                        'tab'                => bbp_get_tab_index(),
    441441                        'options_only'       => false,
    442442                        'show_none'          => __( '&mdash; No parent &mdash;', 'bbpress' ),
     
    480480
    481481        <p>
    482482                <strong class="label"><?php esc_html_e( 'Status:', 'bbpress' ); ?></strong>
    483                 <label class="screen-reader-text" for="post_status"><?php esc_html_e( 'Select what status to give the reply.', 'bbpress' ); ?></label>
    484                 <?php bbp_form_reply_status_dropdown( array( 'select_id' => 'post_status', 'reply_id' => $post_id ) ); ?>
     483                <label class="screen-reader-text" for="bbp_reply_status_select"><?php esc_html_e( 'Select what status to give the reply.', 'bbpress' ); ?></label>
     484                <?php bbp_form_reply_status_dropdown( array( 'reply_id' => $post_id ) ); ?>
    485485        </p>
    486486
    487487        <hr />
     
    495495
    496496                <p>
    497497                        <strong class="label"><?php esc_html_e( 'Forum:', 'bbpress' ); ?></strong>
    498                         <label class="screen-reader-text" for="bbp_forum_id"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label>
     498                        <label class="screen-reader-text" for="bbp_reply_forum_select"><?php esc_html_e( 'Forum', 'bbpress' ); ?></label>
    499499                        <?php bbp_dropdown( array(
    500500                                'post_type'          => bbp_get_forum_post_type(),
    501501                                'selected'           => $reply_forum_id,
     
    506506                                'exclude'            => '',
    507507
    508508                                // Output-related
    509                                 'select_id'          => 'bbp_forum_id',
     509                                'select_id'          => 'bbp_reply_forum_select',
    510510                                'tab'                => bbp_get_tab_index(),
    511511                                'options_only'       => false,
    512512                                'show_none'          => __( '&mdash; No parent &mdash;', 'bbpress' ),
     
    523523
    524524        <p>
    525525                <strong class="label"><?php esc_html_e( 'Topic:', 'bbpress' ); ?></strong>
    526                 <label class="screen-reader-text" for="parent_id"><?php esc_html_e( 'Topic', 'bbpress' ); ?></label>
     526                <label class="screen-reader-text" for="bbp_topic_id"><?php esc_html_e( 'Topic', 'bbpress' ); ?></label>
    527527                <input name="parent_id" id="bbp_topic_id" type="text" value="<?php echo esc_attr( $reply_topic_id ); ?>" />
    528528        </p>
    529529
     
    535535
    536536        <p>
    537537                <strong class="label"><?php esc_html_e( 'Reply To:', 'bbpress' ); ?></strong>
    538                 <label class="screen-reader-text" for="bbp_reply_to"><?php esc_html_e( 'Reply To', 'bbpress' ); ?></label>
     538                <label class="screen-reader-text" for="bbp_reply_to_select"><?php esc_html_e( 'Reply To', 'bbpress' ); ?></label>
    539539                <?php bbp_reply_to_dropdown( $post_id ); ?>
    540540        </p>
    541541
  • src/includes/replies/template.php

     
    25412541                // Get the dropdown and return it
    25422542                $retval = bbp_get_dropdown( array(
    25432543                        'show_none'    => sprintf( esc_attr__( '%1$s - %2$s', 'bbpress' ), $topic_id, bbp_get_topic_title( $topic_id ) ),
    2544                         'select_id'    => 'bbp_reply_to',
     2544                        'select_id'    => 'bbp_reply_to_select',
    25452545                        'exclude'      => $reply_id,
    25462546                        'selected'     => $reply_to,
    25472547                        'post_parent'  => $topic_id,
  • src/templates/default/bbpress/form-forum.php

     
    8888                                        <?php do_action( 'bbp_theme_before_forum_form_type' ); ?>
    8989
    9090                                        <p>
    91                                                 <label for="bbp_forum_type"><?php _e( 'Forum Type:', 'bbpress' ); ?></label><br />
     91                                                <label for="bbp_forum_type_select"><?php _e( 'Forum Type:', 'bbpress' ); ?></label><br />
    9292                                                <?php bbp_form_forum_type_dropdown(); ?>
    9393                                        </p>
    9494
     
    9797                                        <?php do_action( 'bbp_theme_before_forum_form_status' ); ?>
    9898
    9999                                        <p>
    100                                                 <label for="bbp_forum_status"><?php _e( 'Status:', 'bbpress' ); ?></label><br />
     100                                                <label for="bbp_forum_status_select"><?php _e( 'Status:', 'bbpress' ); ?></label><br />
    101101                                                <?php bbp_form_forum_status_dropdown(); ?>
    102102                                        </p>
    103103
     
    106106                                        <?php do_action( 'bbp_theme_before_forum_visibility_status' ); ?>
    107107
    108108                                        <p>
    109                                                 <label for="bbp_forum_visibility"><?php _e( 'Visibility:', 'bbpress' ); ?></label><br />
     109                                                <label for="bbp_forum_visibility_select"><?php _e( 'Visibility:', 'bbpress' ); ?></label><br />
    110110                                                <?php bbp_form_forum_visibility_dropdown(); ?>
    111111                                        </p>
    112112
     
    115115                                        <?php do_action( 'bbp_theme_before_forum_form_parent' ); ?>
    116116
    117117                                        <p>
    118                                                 <label for="bbp_forum_parent_id"><?php _e( 'Parent Forum:', 'bbpress' ); ?></label><br />
     118                                                <label for="bbp_forum_parent_id_select"><?php _e( 'Parent Forum:', 'bbpress' ); ?></label><br />
    119119
    120120                                                <?php
    121121                                                        bbp_dropdown( array(
    122                                                                 'select_id' => 'bbp_forum_parent_id',
     122                                                                'select_id' => 'bbp_forum_parent_id_select',
    123123                                                                'show_none' => __( '(No Parent)', 'bbpress' ),
    124124                                                                'selected'  => bbp_get_form_forum_parent(),
    125125                                                                'exclude'   => bbp_get_forum_id()
  • src/templates/default/bbpress/form-topic.php

     
    111111                                                <?php do_action( 'bbp_theme_before_topic_form_forum' ); ?>
    112112
    113113                                                <p>
    114                                                         <label for="bbp_forum_id"><?php _e( 'Forum:', 'bbpress' ); ?></label><br />
     114                                                        <label for="bbp_forum_id_select"><?php _e( 'Forum:', 'bbpress' ); ?></label><br />
    115115                                                        <?php
    116116                                                                bbp_dropdown( array(
     117                                                                        'select_id' => 'bbp_forum_id_select',
    117118                                                                        'show_none' => __( '(No Forum)', 'bbpress' ),
    118119                                                                        'selected'  => bbp_get_form_topic_forum()
    119120                                                                ) );
     
    130131
    131132                                                <p>
    132133
    133                                                         <label for="bbp_stick_topic"><?php _e( 'Topic Type:', 'bbpress' ); ?></label><br />
     134                                                        <label for="bbp_stick_topic_select"><?php _e( 'Topic Type:', 'bbpress' ); ?></label><br />
    134135
    135136                                                        <?php bbp_form_topic_type_dropdown(); ?>
    136137
     
    142143
    143144                                                <p>
    144145
    145                                                         <label for="bbp_topic_status"><?php _e( 'Topic Status:', 'bbpress' ); ?></label><br />
     146                                                        <label for="bbp_topic_status_select"><?php _e( 'Topic Status:', 'bbpress' ); ?></label><br />
    146147
    147148                                                        <?php bbp_form_topic_status_dropdown(); ?>
    148149