category = _x( 'Single Fields', 'xprofile field type category', 'buddypress' ); $this->name = _x( 'Number', 'xprofile field type', 'buddypress' ); $this->set_format( '/^\d+|-\d+$/', 'replace' ); /** * Fires inside __construct() method for BP_XProfile_Field_Type_Number class. * * @since 2.0.0 * * @param BP_XProfile_Field_Type_Number $this Current instance of * the field type number. */ do_action( 'bp_xprofile_field_type_number', $this ); } /** * Output the edit field HTML for this field type. * * Must be used inside the {@link bp_profile_fields()} template loop. * * @since 2.0.0 * * @param array $raw_properties Optional key/value array of * {@link http://dev.w3.org/html5/markup/input.number.html permitted attributes} * that you want to add. */ public function edit_field_html( array $raw_properties = array() ) { // User_id is a special optional parameter that certain other fields // types pass to {@link bp_the_profile_field_options()}. if ( isset( $raw_properties['user_id'] ) ) { unset( $raw_properties['user_id'] ); } $r = bp_parse_args( $raw_properties, array( 'type' => 'number', 'value' => bp_get_the_profile_field_edit_value(), ) ); ?> get_edit_field_html_elements( $r ); ?> aria-labelledby="-1" aria-describedby="-3">

'number', ) ); ?> get_edit_field_html_elements( $r ); ?>>