Search Results for 'profile fields'
-
Search Results
-
Topic: Cannot add profile fields
The button to update the profile field is blocked by the type box. I cannot press update.
See screen shot https://ibb.co/jyMvngr
I have WordPress 6.6.2 and Buddypress 14.1.0 and in the edit profile page, the options are displayed horizontally like this: https://snipboard.io/DrOLiw.jpg
This does not look good, they do not even have a gap between them. How can I make them display vertically like a list?
My users are being confused by our ‘register’ page as it prompts them to enter a ‘Name’ twice. It prompts them to fill in six forms as follows:
—–
Account Details
Username (required)
Email Address (required)
Choose a Password (required)
Confirm Password (required)Profile Details
Name (required)
Name (required)—–
Should the ‘Name’ option appear twice? It seems wrong.
I have found the option to edit this in the WordPress admin under User > Profile Fields > Signup Fields. But although I can drag the two options which are labelled ‘Name (Primary) (required) (Sign-up)’, I cannot remove either of them. How can I fix this?
I am using BuddyPress 14.1.0 and WordPress 6.5.3.
I’m trying to get the XProfile of the specified user using the API.
My endpoint looks like this:
https://xxxxxxxx/wp-json/buddypress/v1/xprofile/2/data/4As expected, it will get Fields #2 with user ID 4, which has enforced visibility and visibility level onlyme (adminsonly in the database).
But when I used an authentication with admin privileges to get the endpoint, it returned “Sorry, the profile field value is not viewable for this user.”After testing,”All Members” is also invalid, only in “Everyone” API can get data properly
The Buddypress version I am using is 14.0
Topic: Profile field Validation
Is there a way to validate the file type fields, before the saving to db. I am using this hook but it’s not working add_action( ‘xprofile_data_before_save’, ‘validate_required_unshared_fields’);
I want to make users able to add bullet or numeric lists to their profile page. Doesn’t matter if I chose wp user meta bio field or multiline xprofile field, both display lists in user profile as words with linebreaks (br). How can I avoid that and show it like it is saved in db?
Same question here 3 years ago, unanswered.
Hello, I had this code, what it does is that certain users already enter with a subscription and can use the chat without having to pay. When updating to the latest version the code no longer works. Any idea what has changed?:
add_filter(‘bp_get_total_member_count’,’bpfr_hide_get_total_filter’);
function kleo_pmpro_default_level($user_id) {
global $wpdb, $bp;//Change this with your field name
$field_name= “i am”;//Change the field value
$value_to_match = “woman”;//Membership level id
$membership_level = 4;//Done editing
$field_id = $wpdb->get_var( $wpdb->prepare( “SELECT id FROM {$bp->profile->table_name_fields} WHERE name = %s”, $field_name ) );
if ($_POST[‘field_’.$field_id] == $value_to_match) {
pmpro_changeMembershipLevel($membership_level, $user_id);
}
}if (is_multisite()) {
add_action( ‘wpmu_activate_user’, ‘kleo_mu_pmpro_default_level’, 10, 4);
} else {
add_action(‘user_register’, ‘kleo_pmpro_default_level’);
}Thanks!
Topic: Unable to register users
I’m trying to troubleshoot my BuddyPress registration form, which seems to be having some serious problems. I should start by noting that I have added some customizations to my form to add additional data fields, but the registration fails regardless of whether the customizations and overrides are enabled or disabled, and fails in exactly the same manner based on the error log, so the customizations are unlikely to be having an impact.
Here are the hooks that I am using to track where the problem is originating from:
// Hook into various stages of the BuddyPress registration process
add_action( ‘bp_before_registration_submit_buttons’, ‘log_before_registration_submit_buttons’ );
add_action( ‘bp_core_screen_signup’, ‘log_core_screen_signup’ );
add_action( ‘bp_signup_pre_validate’, ‘log_signup_pre_validate’ );
add_action( ‘bp_signup_validate’, ‘ex_custom_bp_signup_validate’ );
add_action( ‘bp_core_signup_user’, ‘log_core_signup_user’, 10, 2 );
add_action( ‘bp_core_activate_user’, ‘log_core_activate_user’, 10, 3 );
add_filter( ‘bp_core_validate_user_signup’, ‘log_core_validate_user_signup’ );
add_filter( ‘bp_core_signup_user_notification’, ‘log_core_signup_user_notification’, 10, 2 );function log_before_registration_submit_buttons() {
error_log( ‘Hook: bp_before_registration_submit_buttons fired.’ );
}function log_core_screen_signup() {
error_log( ‘Hook: bp_core_screen_signup fired.’ );
error_log( ‘Form submission data: ‘ . print_r( $_POST, true ) );
}function log_signup_pre_validate() {
error_log( ‘Hook: bp_signup_pre_validate fired.’ );
}function ex_custom_bp_signup_validate() {
global $bp;
error_log( ‘bp_signup_validate hook fired. Validation errors: ‘ . print_r( $bp->signup->errors, true ) );
}function log_core_signup_user( $user_id, $user_data ) {
error_log( ‘Hook: bp_core_signup_user fired.’ );
error_log( ‘User ID: ‘ . $user_id );
error_log( ‘User Data: ‘ . print_r( $user_data, true ) );
}function log_core_activate_user( $user_id, $key, $user ) {
error_log( ‘Hook: bp_core_activate_user fired.’ );
error_log( ‘User ID: ‘ . $user_id );
error_log( ‘Activation Key: ‘ . $key );
error_log( ‘User Data: ‘ . print_r( $user, true ) );
}function log_core_validate_user_signup( $result ) {
error_log( ‘Hook: bp_core_validate_user_signup fired.’ );
error_log( ‘Validation Result: ‘ . print_r( $result, true ) );
return $result;
}function log_core_signup_user_notification( $user_id, $user_data ) {
error_log( ‘Hook: bp_core_signup_user_notification fired.’ );
error_log( ‘User ID: ‘ . $user_id );
error_log( ‘User Data: ‘ . print_r( $user_data, true ) );
return $user_data;
}Here is a sample of the outputs from testing, with and without the Extended Profiles setting turned on:
[19-Jul-2024 00:01:28 UTC] Hook: bp_core_screen_signup fired.
[19-Jul-2024 00:01:28 UTC] Form submission data: Array
(
[signup_username] => TestUserAlpha
[signup_email] => AlphaEmail@EmailAlpha.com
[signup_password] => xEO^ONJS1ZkY
[signup_password_confirm] => xEO^ONJS1ZkY
[field_1] => Imma User
[signup_profile_field_ids] => 1
[signup-privacy-policy-check] => 1
[signup-privacy-policy-accept] => on
[signup_submit] => Complete Sign Up
[_wpnonce] => 3184f10172
[_wp_http_referer] => /register
)[19-Jul-2024 00:01:28 UTC] Hook: bp_before_registration_submit_buttons fired.
[19-Jul-2024 00:01:32 UTC] Hook: bp_core_screen_signup fired.
[19-Jul-2024 00:01:32 UTC] Form submission data: Array
(
[signup_username] => TestUserBeta
[signup_email] => AlphaEmail@EmailAlpha.com
[signup_password] => oeHAfbtPlIRG
[signup_password_confirm] => oeHAfbtPlIRG
[signup-privacy-policy-check] => 1
[signup-privacy-policy-accept] => on
[signup_submit] => Complete Sign Up
[_wpnonce] => 9240fe3ccc
[_wp_http_referer] => /register
)After poking around in various threads and ChatGPT, the suggestion is that the error is happening in the form validation, and I was told to look at bp-core-signup.php in the bp-core folder. Problem: this file does not exist in my BuddyPress installation. I deleted everything, did a fresh installation, and the file still does not exist. I added the hooks back in, made another test, and got exactly the same result. So am I just straight up missing a file in my installation? Or is there a deeper problem that’s outside the scope of my current awareness?
Topic: New Function Request
Can you add an image upload functionality in the profile section? To elaborate, within the profile, we can create multiple groups with custom fields such as text, textarea, etc. We need to include an image upload field in these groups.
Hi everyone
This code below add Age after the username in the members directory.
/**
* Show Xprofile Field Data After The username in The Members Directory.
*/
function yzc_add_xprofile_field_data_after_username( $name ) {if ( bp_is_members_directory() ) {
$field_data = xprofile_get_field_data( ‘Age’, bp_get_member_user_id() );
return $name . ‘, <span class=”bp-user-age”>’ . $field_data. ‘</span>’;
}return $name;
}
add_filter( ‘bp_member_name’, ‘yzc_add_xprofile_field_data_after_username’, 10 );
Please I also want to include City and Country to this code. Can anyone help me modify this code to also include City and Country?
I am using Extended Profile for a user registration form. I’d like to use the default WordPress bio field (Biographical info). I am able to add it in the Extended Profile settings (under Type -> WordPress Fields -> Biography), but there is no option to require it. I can make other fields required. How could I go about making that field required?
WordPress 6.5.4
BuddyPress 12.5.0I want to be able to add a description that tells users their profile slug would use their username rather than their first or surname. Unfortunately, the username field is not editable in the Profile Fields section of the Buddypress profile like other fields are.
Wondering if there is a different way to add the message?
I have profile fields setup for the registration form. I’ve included a field for the user to choose which groups they’d like to join on signup. However, it doesn’t seem to be mapped(?) to the Groups I have created since the user isn’t added to the group(s) they select in the form. I’ve seen this work on other sites but not sure what I’m missing. I also can’t add them to groups in the user > extended profile either. Any ideas?
I am testing out Buddypress Version 12.5.0 and I made a registration form with Buddypress’ profile fields as well as a third party plugin “User Registration” by WPEverest. I tested both separately and noticed that Buddypress registration form does not collect the surname of the user, only the first name, because there is no field for surnames. I made a separate text box field and named it “surname” but obviously it does not connect to actual surname field in the buddypress and wordpress back end.
User Registration has an actual surname field and can collect the user’s surname which shows up correctly in the back end, but it displays the user’s username as the name when the person logs in. For example if a person’s name is “Jane Doe” but their username is “gelato”, in the top right corner when they log in it says “gelato” which is not good, so I can’t use this.
So I am wondering if anyone has a way to force the Buddypress registration form to collect the surname correctly so it shows in the backend?
Thanks
i’d like to migrate 950 users from a bespoke system to BuddyPress.
i can easily create a CSV file with the user information, including fields that i can create in the Extended Profile.are there suggestions on how to import that CSV file, and ensure that the default Profile Visibility settings are set during the import for those NEW users?
one plug-in that i tried had problems with the Profile Visibility piece.