[buddypress-trac] [BuddyPress Trac] #6549: xprofile field type for phone number

buddypress-trac noreply at wordpress.org
Wed Feb 7 12:07:11 UTC 2018


#6549: xprofile field type for phone number
------------------------------+-----------------------
 Reporter:  danbp             |       Owner:  DJPaul
     Type:  enhancement       |      Status:  assigned
 Priority:  normal            |   Milestone:  3.0
Component:  Extended Profile  |     Version:  2.3.2
 Severity:  normal            |  Resolution:
 Keywords:  has-patch         |
------------------------------+-----------------------

Comment (by DJPaul):

 > phone number validation is an absolute nightmare

 Yes.

 > we make it possible for plugin authors

 {{{
 add_action( 'bp_xprofile_field_type_telephone', function( $field_type_obj
 ) {
   $field_type_obj->set_format( '/your_phone_number_regex_here/', 'replace'
 );
 } );
 }}}

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6549#comment:8>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list