Try this on for size. Hackish but functional, until real exclude arguments exist (they’re coming in 1.3, I promise!) Put it in your bp-custom.php
`function bbg_disallow_name_edit( $has_profile ) {
global $profile_template, $bp;
if ( ‘edit’ != $bp->current_action || !bp_is_my_profile() )
return $has_profile;
foreach( (array)$profile_template->groups as $group_key => $group ) {
foreach( (array)$group->fields as $field_key => $field ) {
if ( $field->name == BP_XPROFILE_FULLNAME_FIELD_NAME ) {
unset( $profile_template->groups[$group_key]->fields[$field_key] );
$profile_template->groups[$group_key]->fields = array_values(
$profile_template->groups[$group_key]->fields );
break 2;
}
}
}
return $has_profile;
}
add_filter( ‘bp_has_profile’, ‘bbg_disallow_name_edit’ );`
Thank you mate, I will try this now. Btw in wordpress version 1.3, will be able to disable this part of the profile?
Sorry, i cant find the bp.customs.php file..
bp-custom.php is a file you may create and place in the wp-content/plugins/ directory.
https://codex.buddypress.org/buddypress-site-administration/bp-custom-php/
ok great it works, just one question. How come i got the button base showing now? It doesnt do anything and what is base? Dont understand why its there, Thanks!!
just one question. How come i got the button base showing now? It doesnt do anything and what is base? Dont understand why its there, Thanks!!
Please don’t bump your post more than once per day, especially on the weekend.
The Base button corresponds to the Base profile fields group. There is no easy way to turn this off at this time.