Replies
Hi Jill,
Please use the following code// disable the custom profile background generated css. add_filter( 'bppg_iwilldo_it_myself', '__return_true' );//do not generate css for us //Our own css function buddydev_custom_inject_css() { if ( ! function_exists( 'bppg_get_image' ) ) { return ;// no trouble when the plugin is disabled } $image_url = bppg_get_image(); if ( empty( $image_url ) ) { return; } $repeat_type = bp_get_user_meta( bp_displayed_user_id(), 'profile_bg_repeat', true ); if ( ! $repeat_type ) { $repeat_type = 'repeat'; } ?> <style type="text/css"> body.is-user-profile #buddypress div#item-body{ background: url(<?php echo $image_url; ?>); background-repeat: <?php echo $repeat_type; ?>; } </style> <?php } add_action( 'wp_head', 'buddydev_custom_inject_css', 200 );You may experiemnet with the css selector to aplly the image to various other parts.
Best Regards
Brajesh- Brajesh Singh on April 16, 2018 at 7:12 pm in reply to: [Resolved] BP Profile Tab Pro – Default Tab Error #14542
Hi Sujee,
You are correct about the default tab. It applies to all or none.if you can tell me about your member types and provide the slugs for applying to these types, I can help with code.
You will have to remove the default selection for the tab from the profile tabs plugin in that case.
Regards
Brajesh - Brajesh Singh on April 16, 2018 at 5:12 pm in reply to: Help with creating an import add-on for WP All Import and Mediapress #14541
Thank you. Will certainly do. The focus will be on import after 2.0
Hi Keith,
BuddyPress Activities can have only 2 privacy either visible to all or only visible to the poster(It may change if the Core developers decide to add ebtetr privacy in future).For MediaPress, if an item is accessible to all(including non logged), Its activity is set public otherwise it is set as private.
What you are seeing is the correct listing for a logged in users only gallery.
Regards
BrajeshHi Tosin,
I won’t be able to look into it and assist as we have a moderation plugin coming this week and I am investing my time on that. Once the plugin is available and you still feel you need to use this code, Please feel free to post back and I or one of our team members will help.At the moment, I am just trying to avoid any duplicate effort.
Thank you
Brajesh- Brajesh Singh on April 16, 2018 at 5:06 pm in reply to: [Resolved] Prevent buddypress unfollow function for specified users #14536
Marking it closed in favour of
https://buddydev.com/support/forums/topic/prevent-buddypress-unfollow-function-for-specified-users-2/- This reply was modified 8 years ago by
Brajesh Singh.
- This reply was modified 8 years ago by
- Brajesh Singh on April 16, 2018 at 5:05 pm in reply to: [Resolved] Prevent buddypress unfollow function for specified users #14535
Please use the following code to hide the button
/** * @param array $args button args. * @param int $leader_id leader to be followed. * @param int $follower_id follower id. * * @return mixed */ function buddydev_hide_unfollow_button_for_users( $args, $leader_id, $follower_id ) { if ( 'following' !== $args['id'] ) { return $args; } // user ids who can not be unfollowed. $special_user_ids = array( 1,2,3,67 ); if ( in_array( $leader_id, $special_user_ids ) ) { $args['id'] = ''; } return $args; } add_filter( 'bp_follow_get_add_follow_button', 'buddydev_hide_unfollow_button_for_users', 10, 3 );It only hides the button but does not do anything else to stop unfollowing.
Regards
Brajesh - Brajesh Singh on April 16, 2018 at 4:42 pm in reply to: [Resolved] "Links xprofile" & NEW PLUGIN #14533
Hi Julia,
That was expected. Specially on the edit page. BuddyPress doe snot give any specific error on the profile edit page. That’s why I asked you to put a message in the description.The better and accessible way will need too much code for a simple task like this.
2. sure, You can use any of the available javascript plugins to do that. I don’t have enough time to find a library and post the code. I will leave it upto you to find and use it.
Regards
Brajesh - Brajesh Singh on April 16, 2018 at 4:38 pm in reply to: BP Limit Friends Request + Rate Limit Private Message + Rate Limit User Activity #14532
Thank you.
- Brajesh Singh on April 16, 2018 at 4:38 pm in reply to: [Resolved] Hide current logged in user and admin #14530
You are welcome.