Replies
You are welcome.
If you have issues in using any normal shortcode, Please do let me know.
Regards
Brajesh- Brajesh Singh on March 9, 2021 at 11:17 am in reply to: [Resolved] Problem to Setting Auto Friendship #36739
Hi Emanuele,
Thank you.Please do. That will help us check and update the code as needed.
Thank you
Brajesh - Brajesh Singh on March 9, 2021 at 11:06 am in reply to: [Resolved] Problem to Setting Auto Friendship #36737
Hi Emanuele,
Did you try to change a user’s member type after puttin the code from my last update?Regards
Brajesh - Brajesh Singh on March 9, 2021 at 9:17 am in reply to: [Resolved] FB like activity stream not working #36735
Thank you Hugo.
I am checking it now. will update you in 2-3 hours.Regards
Brajesh - Brajesh Singh on March 8, 2021 at 7:07 pm in reply to: [Resolved] BuddyPress Friends Suggestions Pro Error #36724
Hi Tiffany,
We have looked into the plugin but are unable to replicate the error. There was no “IN, NOT In” operator support.Do you have any staging site where i can check your profile fields and the Rules for sugegstions.
Regards
Brajesh - Brajesh Singh on March 8, 2021 at 7:04 pm in reply to: Is there a way to display Custom Xprofile fields using shortcode? #36723
Hi,
Thank you for sharing the details.You can remove the plugin and put this code in theme theme’s functions.php
/** * Xprofile data shortcode. */ add_shortcode( 'bpc-profile-data', function ( $atts = array(), $content = null ) { $atts = shortcode_atts( array( 'context' => '', // logged, displayed, author 'user_id' => 0, 'field' => '', ), $atts ); if ( empty( $atts['field'] ) ) { return ''; } $user_id = 0; switch ( $atts['context'] ) { case 'displayed': $user_id = bp_displayed_user_id(); break; case 'logged': $user_id = get_current_user_id(); break; case 'author': $user_id = get_the_author_meta( 'ID' ); break; default: if ( $atts['user_id'] ) { $user_id = $atts['user_id']; } elseif ( in_the_loop() ) { $user_id = get_the_author_meta( 'ID' ); } elseif ( bp_is_user() ) { $user_id = bp_displayed_user_id(); } elseif ( is_user_logged_in() ) { $user_id = get_current_user_id(); } } if ( ! $user_id ) { return ''; } return xprofile_get_field_data( $atts['field'], $user_id, 'comma' ); } );Now, you can use the shortcode like this
[bpc-profile-data field="About" ]You can use either the content or the user_id parameter to pass user context or id.
Regards
Brajesh - Brajesh Singh on March 8, 2021 at 6:54 pm in reply to: Adding div class around Show Xprofile Field Data in The Profile Header code #36722
Hi Carsten,
I am sorry for the delayed reply.By mistake, I had made the code to show the data only if the “Age” was set. Please use this instead
/** * Buddypress Show Xprofile Field Data in The Profile Header. */ function yzc_add_xprofile_field_data_in_profile_header( $name ) { $field_data = xprofile_get_field_data( 'Age', bp_displayed_user_id() ); echo "<div class='profile-job-info'>"; echo '<br/><strong>Alder:</strong> ' . $field_data; $field_data = xprofile_get_field_data( 'From', bp_displayed_user_id() ); if ( ! empty( $field_data ) ) { echo ' <br/> <strong>Fra:</strong> ' . $field_data; $field_data = xprofile_get_field_data( 'Job', bp_displayed_user_id() ); if ( ! empty( $field_data ) ) { echo '<br/><strong>Job:</strong> ' . $field_data; } echo '</div>'; } } add_action( 'bp_before_member_header_meta', 'yzc_add_xprofile_field_data_in_profile_header' );Regards
Brajesh - Brajesh Singh on March 8, 2021 at 6:51 pm in reply to: [Resolved] how to remove icon's text for community builder theme for mobile devices? #36721
Hi,
Thank you for the reply.In community Builder 2.x, the only way to reorder nav is to either use BuddyPress Reorder Profile Tabs plugin or BuddyPress User Profile Tabs Creator Pro.
Regards
Brajesh - Brajesh Singh on March 8, 2021 at 6:40 pm in reply to: [Resolved] Couldn't Set a Profile Tab as Default Component #36720
Hi Khalid,
Thank you for letting us know. I am glad it is resolved.Regards
Brajesh - Brajesh Singh on March 8, 2021 at 6:39 pm in reply to: [Resolved] Mr. Deoveloper! I want to one function. #36719
Hi,
Thank you for the topic.We do have a plugin for the same. I am asking @ravisharma to look into it and release.
Regards
Brajesh