[buddypress-trac] [BuddyPress Trac] #7304: xProfile Group field

buddypress-trac noreply at wordpress.org
Tue Oct 25 14:44:30 UTC 2016


#7304: xProfile Group field
------------------------------+-----------------
 Reporter:  danbp             |      Owner:
     Type:  defect (bug)      |     Status:  new
 Priority:  normal            |  Milestone:
Component:  Extended Profile  |    Version:  2.7
 Severity:  normal            |   Keywords:
------------------------------+-----------------
 I'm unable to hide a profile field group from the profile edit screen by
 using following function. It worked in the past, at least 2.1.

 Not sure it is a bug, but if somebody could confirm.


 {{{
 function bpfr_hide_profile_field_group( $retval ) {

         if ( bp_is_active( 'xprofile' ) ) :

         // hide profile group/field to all except admin
         //if ( !is_super_admin() ) {
         // hide fields & group tabs on edit screen
         if( bp_is_user_profile_edit() ) {
                 //exlude fields, separated by comma
                 //$retval['exclude_fields'] = '1';
                 //exlude groups, separated by comma
                 $retval['exclude_groups'] = '3';
         }
         return $retval;

         endif;
 }
 add_filter( 'bp_after_has_profile_parse_args',
 'bpfr_hide_profile_field_group' );
 }}}

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/7304>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list