Skip to:
Content

BuddyPress.org

Changeset 10301


Ignore:
Timestamp:
10/22/2015 01:43:46 AM (4 years ago)
Author:
mercime
Message:

xProfile: Add label for textbox fields in wp-admin.

See #6655.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-field-type-textbox.php

    r10179 r10301  
    9292        $r = bp_parse_args( $raw_properties, array(
    9393            'type' => 'text'
    94         ) ); ?>
     94        ) );
    9595
    96         <input <?php echo $this->get_edit_field_html_elements( $r ); ?>>
     96        if ( is_admin() ) : ?>
     97
     98            <label for="<?php bp_the_profile_field_input_name(); ?>" class="screen-reader-text"><?php esc_html_e( 'Textbox', 'buddypress' ); ?></label>
     99            <input <?php echo $this->get_edit_field_html_elements( $r ); ?>>
     100
     101        <?php else : ?>
     102
     103            <input <?php echo $this->get_edit_field_html_elements( $r ); ?>>
     104
     105        <?php endif; ?>
    97106
    98107        <?php
Note: See TracChangeset for help on using the changeset viewer.