Ticket #7348: 7348.patch
File 7348.patch, 13.7 KB (added by , 8 years ago) |
---|
-
src/bp-templates/bp-legacy/buddypress/members/register.php
174 174 $field_type = bp_xprofile_create_field_type( bp_get_the_profile_field_type() ); 175 175 $field_type->edit_field_html(); 176 176 177 if ( bp_get_the_profile_field_description() ) : ?> 178 <p class="description" id="<?php bp_the_profile_field_input_name(); ?>-3"><?php bp_the_profile_field_description(); ?></p> 179 <?php endif; 180 177 181 /** 178 182 * Fires before the display of the visibility options for xprofile fields. 179 183 * … … 182 186 do_action( 'bp_custom_profile_edit_fields_pre_visibility' ); 183 187 184 188 if ( bp_current_user_can( 'bp_xprofile_change_field_visibility' ) ) : ?> 185 <p class="field-visibility-settings-toggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"> 189 <p class="field-visibility-settings-toggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"><span id="<?php bp_the_profile_field_input_name(); ?>-2"> 186 190 <?php 187 191 printf( 188 192 __( 'This field can be seen by: %s', 'buddypress' ), … … 189 193 '<span class="current-visibility-level">' . bp_get_the_profile_field_visibility_level_label() . '</span>' 190 194 ); 191 195 ?> 192 <button type="button" class="visibility-toggle-link"><?php _ex( 'Change', 'Change profile field visibility level', 'buddypress' ); ?></button> 196 </span> 197 <button type="button" class="visibility-toggle-link" aria-describedby="<?php bp_the_profile_field_input_name(); ?>-2"><?php _ex( 'Change', 'Change profile field visibility level', 'buddypress' ); ?></button> 193 198 </p> 194 199 200 195 201 <div class="field-visibility-settings" id="field-visibility-settings-<?php bp_the_profile_field_id() ?>"> 196 202 <fieldset> 197 203 <legend><?php _e( 'Who can see this field?', 'buddypress' ) ?></legend> … … 222 228 */ 223 229 do_action( 'bp_custom_profile_edit_fields' ); ?> 224 230 225 <p class="description"><?php bp_the_profile_field_description(); ?></p>226 227 231 </div> 228 232 229 233 <?php endwhile; ?> -
src/bp-templates/bp-legacy/buddypress/members/single/profile/edit.php
43 43 $field_type = bp_xprofile_create_field_type( bp_get_the_profile_field_type() ); 44 44 $field_type->edit_field_html(); 45 45 46 if ( bp_get_the_profile_field_description() ) : ?> 47 <p class="description" id="<?php bp_the_profile_field_input_name(); ?>-3"><?php bp_the_profile_field_description(); ?></p> 48 <?php endif; 49 46 50 /** 47 51 * Fires before the display of visibility options for the field. 48 52 * … … 52 56 ?> 53 57 54 58 <?php if ( bp_current_user_can( 'bp_xprofile_change_field_visibility' ) ) : ?> 55 <p class="field-visibility-settings-toggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"> 59 <p class="field-visibility-settings-toggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"><span id="<?php bp_the_profile_field_input_name(); ?>-2"> 56 60 <?php 57 61 printf( 58 62 __( 'This field can be seen by: %s', 'buddypress' ), … … 59 63 '<span class="current-visibility-level">' . bp_get_the_profile_field_visibility_level_label() . '</span>' 60 64 ); 61 65 ?> 62 <button type="button" class="visibility-toggle-link"><?php _e( 'Change', 'buddypress' ); ?></button> 66 </span> 67 <button type="button" class="visibility-toggle-link" aria-describedby="<?php bp_the_profile_field_input_name(); ?>-2"><?php _ex( 'Change', 'Change profile field visibility level', 'buddypress' ); ?></button> 63 68 </p> 64 69 65 70 <div class="field-visibility-settings" id="field-visibility-settings-<?php bp_the_profile_field_id() ?>"> … … 91 96 */ 92 97 do_action( 'bp_custom_profile_edit_fields' ); ?> 93 98 94 <p class="description"><?php bp_the_profile_field_description(); ?></p>95 99 </div> 96 100 97 101 <?php endwhile; ?> -
src/bp-xprofile/bp-xprofile-template.php
1282 1282 // Parse optional arguments. 1283 1283 $r = bp_parse_args( $args, array( 1284 1284 'field_id' => bp_get_the_profile_field_id(), 1285 'before' => '< ulclass="radio">',1286 'after' => '</ ul>',1287 'before_radio' => ' <li class="%s">',1288 'after_radio' => ' </li>',1285 'before' => '<div class="radio">', 1286 'after' => '</div>', 1287 'before_radio' => '', 1288 'after_radio' => '', 1289 1289 'class' => 'bp-xprofile-visibility' 1290 1290 ), 'xprofile_visibility_radio_buttons' ); 1291 1291 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-checkbox.php
82 82 'user_id' => $user_id 83 83 ) ); ?> 84 84 85 </fieldset>86 87 85 <?php 88 86 } 89 87 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-datebox.php
138 138 139 139 </div> 140 140 141 </fieldset>142 141 <?php 143 142 } 144 143 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-multiselectbox.php
73 73 'name' => bp_get_the_profile_field_input_name() . '[]', 74 74 ) ); ?> 75 75 76 <fieldset class="multiselectbox"> 77 <legend><?php bp_the_profile_field_name(); ?></legend> 78 76 79 <label for="<?php bp_the_profile_field_input_name(); ?>[]"> 77 < ?php bp_the_profile_field_name(); ?>80 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 78 81 <?php bp_the_profile_field_required_label(); ?> 79 82 </label> 80 83 … … 83 86 /** This action is documented in bp-xprofile/bp-xprofile-classes */ 84 87 do_action( bp_get_the_profile_field_errors_action() ); ?> 85 88 86 <select <?php echo $this->get_edit_field_html_elements( $r ); ?> >89 <select <?php echo $this->get_edit_field_html_elements( $r ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"> 87 90 <?php bp_the_profile_field_options( array( 88 91 'user_id' => $user_id 89 92 ) ); ?> … … 91 94 92 95 <?php if ( ! bp_get_the_profile_field_is_required() ) : ?> 93 96 94 <a class="clear-value" href="javascript:clear( '<?php echo esc_js( bp_get_the_profile_field_input_name() ); ?>[]' );" >97 <a class="clear-value" href="javascript:clear( '<?php echo esc_js( bp_get_the_profile_field_input_name() ); ?>[]' );" role="button"> 95 98 <?php esc_html_e( 'Clear', 'buddypress' ); ?> 96 99 </a> 97 100 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-number.php
65 65 'value' => bp_get_the_profile_field_edit_value() 66 66 ) ); ?> 67 67 68 <fieldset class="number-type"> 69 <legend><?php bp_the_profile_field_name(); ?></legend> 70 68 71 <label for="<?php bp_the_profile_field_input_name(); ?>"> 69 < ?php bp_the_profile_field_name(); ?>72 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 70 73 <?php bp_the_profile_field_required_label(); ?> 71 74 </label> 72 75 … … 75 78 /** This action is documented in bp-xprofile/bp-xprofile-classes */ 76 79 do_action( bp_get_the_profile_field_errors_action() ); ?> 77 80 78 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> >81 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"> 79 82 80 83 <?php 81 84 } -
src/bp-xprofile/classes/class-bp-xprofile-field-type-radiobutton.php
87 87 88 88 <?php endif; ?> 89 89 90 </fieldset>91 92 90 <?php 93 91 } 94 92 … … 176 174 return; 177 175 } ?> 178 176 179 <a class="clear-value" href="javascript:clear( '<?php echo esc_js( bp_get_the_profile_field_input_name() ); ?>' );" >177 <a class="clear-value" href="javascript:clear( '<?php echo esc_js( bp_get_the_profile_field_input_name() ); ?>' );" role="button"> 180 178 <?php esc_html_e( 'Clear', 'buddypress' ); ?> 181 179 </a> 182 180 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-selectbox.php
65 65 $user_id = bp_displayed_user_id(); 66 66 } ?> 67 67 68 <fieldset class="selectbox"> 69 <legend><?php bp_the_profile_field_name(); ?></legend> 70 68 71 <label for="<?php bp_the_profile_field_input_name(); ?>"> 69 < ?php bp_the_profile_field_name(); ?>72 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 70 73 <?php bp_the_profile_field_required_label(); ?> 71 74 </label> 72 75 … … 75 78 /** This action is documented in bp-xprofile/bp-xprofile-classes */ 76 79 do_action( bp_get_the_profile_field_errors_action() ); ?> 77 80 78 <select <?php echo $this->get_edit_field_html_elements( $raw_properties ); ?> >81 <select <?php echo $this->get_edit_field_html_elements( $raw_properties ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"> 79 82 <?php bp_the_profile_field_options( array( 'user_id' => $user_id ) ); ?> 80 83 </select> 81 84 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-textarea.php
63 63 64 64 $richtext_enabled = bp_xprofile_is_richtext_enabled_for_field(); ?> 65 65 66 <fieldset class="textarea"> 67 <legend><?php bp_the_profile_field_name(); ?></legend> 68 66 69 <label for="<?php bp_the_profile_field_input_name(); ?>"> 67 < ?php bp_the_profile_field_name(); ?>70 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 68 71 <?php bp_the_profile_field_required_label(); ?> 69 72 </label> 70 73 … … 81 84 82 85 ?> 83 86 84 <textarea <?php echo $this->get_edit_field_html_elements( $r ); ?> ><?php bp_the_profile_field_edit_value(); ?></textarea>87 <textarea <?php echo $this->get_edit_field_html_elements( $r ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"><?php bp_the_profile_field_edit_value(); ?></textarea> 85 88 86 89 <?php 87 90 -
src/bp-xprofile/classes/class-bp-xprofile-field-type-textbox.php
64 64 'value' => bp_get_the_profile_field_edit_value(), 65 65 ) ); ?> 66 66 67 <fieldset class="textbox"> 68 <legend><?php bp_the_profile_field_name(); ?></legend> 69 67 70 <label for="<?php bp_the_profile_field_input_name(); ?>"> 68 < ?php bp_the_profile_field_name(); ?>71 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 69 72 <?php bp_the_profile_field_required_label(); ?> 70 73 </label> 71 74 … … 74 77 /** This action is documented in bp-xprofile/bp-xprofile-classes */ 75 78 do_action( bp_get_the_profile_field_errors_action() ); ?> 76 79 77 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> >80 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"> 78 81 79 82 <?php 80 83 } -
src/bp-xprofile/classes/class-bp-xprofile-field-type-url.php
66 66 'value' => esc_url( bp_get_the_profile_field_edit_value() ), 67 67 ) ); ?> 68 68 69 <fieldset class="url"> 70 <legend><?php bp_the_profile_field_name(); ?></legend> 71 69 72 <label for="<?php bp_the_profile_field_input_name(); ?>"> 70 < ?php bp_the_profile_field_name(); ?>73 <span class="bp-screen-reader-text"><?php bp_the_profile_field_name(); ?></span> 71 74 <?php bp_the_profile_field_required_label(); ?> 72 75 </label> 73 76 … … 76 79 /** This action is documented in bp-xprofile/bp-xprofile-classes */ 77 80 do_action( bp_get_the_profile_field_errors_action() ); ?> 78 81 79 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> >82 <input <?php echo $this->get_edit_field_html_elements( $r ); ?> aria-describedby="<?php bp_the_profile_field_input_name(); ?>-3"> 80 83 81 84 <?php 82 85 }