Search Results for 'buddypress'
-
AuthorSearch Results
-
July 14, 2016 at 7:17 pm #256611
r-a-y
KeymasterTry disabling all BuddyPress plugins and try duplicating the problem again.
My guess is the problem is with the BuddyPress Wall plugin. Deactivate that and see if your problem pops up again.
Do you have any specific steps to duplicate your problem? Does the problem occur after replying under a certain comment depth or when you hit a certain number of comments in the group update?
July 14, 2016 at 7:01 pm #256609r-a-y
Keymaster@tutorbe – Thanks for mentioning that you are testing on HHVM.
I personally haven’t tested HHVM with BP 2.6.1.1 yet.
Can you turn
WP_DEBUGon inwp-config.phpand note down any debug notices that are showing up with BP 2.6.1.1?What happens if you disable class autoloading manually by commenting out these lines?
https://buddypress.trac.wordpress.org/browser/tags/2.6.1.1/src/bp-loader.php?marks=469-470#L467Let me know if that works or not.
July 14, 2016 at 4:57 pm #256599danbp
ParticipantHi,
apparently there is a conflict somewhere. Do you receive php notice or warnings with wp_debug activated ? The fn you mention posts new Activity comments received via a POST request.
Before opening a ticket, can you provide some more details about your install please ? Server type, php version and memory_limit.
Theme
Is Valenti theme updated to fit with BuddyPress 2.6 ? No information about this detail on the theme presentation even if recent update (23/6/2016). But it’s crucial to know, as many things changed in 2.6+Plugins
Hashbuddy wasn’t updated since 2 years.
Do you use WDS-BuddyPress-Project-Framework ?Debug
To test, you can deactivate all plugins except BP. It’s important you ensure that at least the basic install of WP+BP is fully working. First with a twenty theme and second, with your theme (not the child).If the site is for a client, you’re a pro. Hopefully you have a sandbox install (locally or online) to do this debug work ?!!!
July 14, 2016 at 8:44 am #256590In reply to: Recommend caching plugin for BP
tonywillis
ParticipantSo is this is definite “Object cache doesn’t work inside W3 Total Cache” because it breaks password resets? This seems to be my experience.. I’ve whitelisted registration, membership (Paid Memberships Pro) and activation pages in the page cache but seem to have issues with password reset and account activation since using activating xcache Object Cache within W3.
So my questions are:
1) is there a different object cache plugin I could use alongside w3 (which is great for its page cache etc)?
2) is this issue unique to xcache? Could I use APC instead?
3) are there any other integrated cache solutions that work with Buddypress that include object cache? The benefits to my site speed have been huge since activating.. It’s just the account activation issue
ThanksJuly 14, 2016 at 2:45 am #256578In reply to: Add $_POST data before submitting registration
coffeywebdev
Participantalso ‘bp_signup_validate’
function bp_password_beefing() { global $bp; if ( !empty( $_POST['signup_password'] ) ) if ( strlen( $_POST['signup_password'] ) < 6 ) $bp->signup->errors['signup_password'] = __( 'Your password needs to be at least 6 characters', 'buddypress' ); } add_action( 'bp_signup_validate', 'bp_password_beefing');July 14, 2016 at 12:20 am #256573In reply to: Add $_POST data before submitting registration
coffeywebdev
ParticipantCopy the buddypress theme into your WordPress child theme, and then you can modify the register template if needed.
copy the buddypress theme into your child theme by pasting this path into your child theme folder
/wp-content/plugins/buddypress/bp-templates/bp-legacy/buddypresspath of file for registration fields is this:
/wp-content/themes/child-theme/buddypress/members/register.phpThen, add First and Last name fields under User>Profile Links in the WordPress Dashboard.
Currently there is a ‘Name’ field that is required, you can edit it to read ‘First Name’ then add another ‘Last Name’ field..
Then you need to process the data before it saves into the database, I’m kind of at a loss here… I would need more time to brainstorm on it but I did find this hook ‘bp_core_signup_user’
I believe this is the hook you are looking for:
// define the bp_core_signup_user callback function action_bp_core_signup_user( $array, $int, $int ) { // make action magic happen here... }; // add the action add_action( 'bp_core_signup_user', 'action_bp_core_signup_user', 10, 3 );July 13, 2016 at 11:14 pm #256569In reply to: will the buddypress be compatible with php7?
danbp
ParticipantJuly 13, 2016 at 9:25 pm #256562In reply to: Autocomplete usernames when cosing private message
shanebp
ModeratorAssuming there are no errors on your site….
afaik, the auto-complete only handles friends by default. So if you aren’t friends with ‘Jenn’, you won’t see a suggestion.To turn on auto-complete for all users, put this in bp-custom.php :
define( 'BP_MESSAGES_AUTOCOMPLETE_ALL', true );July 13, 2016 at 12:56 pm #256551In reply to: will the buddypress be compatible with php7?
venturavan2
ParticipantI just installed WP Engine PHP Compatibility Checker plugin on one of my A2 hosting sites which is running PHP 7.08. 78 errors and 11 warnings from the Buddypress 2.6.11
Who do I send the Checker log file to (if anyone)?
July 13, 2016 at 1:52 am #256541nickrobinson352
ParticipantHere is the function where I create a dynamic Menu . This function is called from a ‘wp_nav_menu_items’ filter function. The below function creates a dynamic menu based on the buddypress groups the user is entitled to. The idea is to provide navigation to the groups directly via a Menu.
function get_entitled_groups_menu_html() { $dataset = getDS_entitled_groups(); $html = ""; foreach($dataset as $row) { $url = site_url()."/groups/".$row->slug; $html .= '<ul id="menu-item-381" align="right" class="bp-menu bp-groups-nav current_page_item current-menu-item menu-item menu-item-type-bp_nav menu-item-object-bp_loggedin_nav menu-item-381">'; $html .= '<a href="'.$url.'">'.$row->name.'</a></ul>'; } return $html; }The menu renders properly, however when clicked I get the warning. I know I can suppress the warning by turning WP_DEBUG off, but the fact that it does not throw an warning, when I navigate to the group page via going to groups page and then selecting the individual group, but only does when I navigate via this function makes me think there must be a better way.
July 12, 2016 at 8:25 pm #256536In reply to: override bp_show_blog_signup_form()
socialc
Participant@henrywright Tidy, I’ve been away from BuddyPress for a while but this is achieable. Thanks.
July 12, 2016 at 6:11 pm #256534In reply to: tinymce post-form missing “post update” button
danbp
ParticipantStripped tags ? See a possible solution here:
https://buddypress.org/support/topic/remove-html-tags-excluding-image-tag-from-activity-stream/#post-234068July 12, 2016 at 8:12 am #256523In reply to: override bp_show_blog_signup_form()
Henry Wright
ModeratorHi @socialc
The Template Hierarchy will let you override create.php. In your own version of that file you could use
custom_show_blog_signup_form()in place ofbp_show_blog_signup_form(). I’d copy everything frombp_show_blog_signup_form()to your custom function and edit what you need to.July 12, 2016 at 7:19 am #256518In reply to: Improving profile picture upload
danbp
ParticipantIn addition, and relative to this point:
Often people don’t have a profile picture on their harddrive/desktopyou can use BP Avatar Suggestion
If profile informations are important for your project, you can also use my BuddyPress Progress Bar plugin, which helps any site administrator to kindly remember his community members to complete their profile in a clear, significant and non-obstrusive way.
July 12, 2016 at 7:09 am #256516In reply to: Is filtering Activity on CPT meta info possible?
danbp
ParticipantHi,
it’s not the solution but an example you can perhaps use.
The snippet handles the object members and sort them by type “contributing”
Replace object by activity and type by “beer” and see what you can do from that.// add order options to members loop function ch_member_order_options() { ?> <option value="contributing"><?php _e( 'Contributing Members', 'buddypress' ); ?></option> <?php } add_action( 'bp_members_directory_order_options', 'ch_member_order_options' ); // filter ajax members by contributing function ch_filter_ajax_querystring( $querystring = '', $object = '' ) { if( $object != 'members' ) return $querystring; $defaults = array( 'type' => 'active', 'action' => 'active', 'scope' => 'all', 'page' => 1, 'user_id' => 0, 'search_terms' => '', 'exclude' => false, ); $ch_querystring = wp_parse_args( $querystring, $defaults ); if( $ch_querystring['type'] == 'contributing' ) { // grab members by Member Type role declared on xprofile $users = get_users( array( 'fields' => array( 'ID' ), 'role' => 'contributor' ) ); $users_str = ''; foreach ( $users as $user ) { $users_str .= $user->ID . ','; } $users_str = rtrim($users_str, ","); $ch_querystring['include'] = $users_str; $ch_querystring['type'] = 'alphabetical'; return $ch_querystring; } else return $querystring; } add_filter( 'bp_ajax_querystring', 'ch_filter_ajax_querystring', 20, 2 );https://buddypress.org/support/topic/adding-new-order-by-on-members-loop/
July 12, 2016 at 4:08 am #256513In reply to: Is filtering Activity on CPT meta info possible?
Ben Riga
ParticipantI am struggling with this one so any nudge in the right direction (however small) would be great.
I have tried going at it from the other direction but that seems like it will duplicate a lot of BuddyPress code and so doesn’t feel right. By this I mean, if I can’t query the BuddyPress activities based on the meta from the cpt the activities come from, I figured I could try querying the original CPT and filtering on the meta (easily done) and then outputting those as if they are activities. I’ve gotten quite far down that path by duplicating a lot of the code from activity\entry.php. But I’m missing a lot still calculating the date, adding comments, favoriting/reactions etc etc. It doesn’t feel right though and I’m sure I’ll miss things so that the two will never be the same and I’ll be stuck maintaining something that I prob should never have written.
One thought I had was that it might be possible to pull the cpt and find the associated activity id (like secondary_item_id in activity but in the other direction). I have not found a link between the two in that direction.
Then I thought, well if that link from cpt-to-activity is not available by default maybe I could grab it at the time of the initial creation of the activity and save it. Is that possible?
Apologies if this is starting to sound like a stream of consciousness. I’m complete lost right now.
Thanks for any help and support.
Regards,
BenJuly 11, 2016 at 11:51 pm #256510r-a-y
KeymasterI cannot duplicate this on my local nginx test site.
Are you testing with no plugins? If not, disable all BuddyPress plugins and code snippets and try again.
Also try looking at your
nginx.conffile and see if it needs to be tweaked.July 11, 2016 at 11:15 pm #256507r-a-y
KeymasterYou have some other BuddyPress plugins that is causing this notice.
For now, I would recommend turning off
WP_DEBUGmode on your production site.July 11, 2016 at 9:53 pm #256503In reply to: tinymce post-form missing “post update” button
phucitol
ParticipantThanks so much for your quick responses. I’m not explaining myself well I guess.
I want my users to only see and use the visual editor. I know that the button to submit is on the page. I know it is being hidden by javascript on page load. I know that it normally becomes visible when clicking in the textarea. The text area in the visual editor, located in an iframe, doesn’t register the events that make the submit button visible.
Do you know if it is possible to get the buddypress javascript that handles the buttons visibility to work with the text area in the iframe?
Alternatively, would it be possible for me to write custom buttons and add them to the default BP textarea?
July 11, 2016 at 8:33 pm #256498In reply to: How to hide profile menu items from other users
danbp
ParticipantI use that function bpfr_custom_group_default_tab and it works.
Have you replaced the group slug to yours in ‘case’ ? This must fit the exact slug, the one you see by mouse over the group name in the bottom left corner of your brower (and normally in the browser’s address bar).Please ask one question at a time. Make an effort to be clear. It’s difficult to follow your post !
– I want to do this on profile: details, item names…
– I want to do this on groups: details, item names…
NB 1: if you want to change the landing tab for ALL groups, you can use:
define( 'BP_GROUPS_DEFAULT_EXTENSION', 'members' );With this, all groups will use the group members directory as landing tab instead the group activity.
If you want a different landing tab for each group, use the snippet and don’t use define.NB 2: the tab name has no influence on the landing tab. The name and the slug are handled separately, precisely because of that
NB 3: where you put functions in bp-custom has no importance.
July 11, 2016 at 6:15 pm #256492In reply to: tinymce post-form missing “post update” button
danbp
ParticipantJuly 11, 2016 at 6:02 pm #256490In reply to: How to hide profile menu items from other users
danbp
ParticipantThe Home tab is the default one. If you remove that tab, BP has no way to know where to output the other group tabs content. If you remove Home(aka activity) you should define another landing tab.
But when you want to modify groups, you shouldn’t define ‘profile’, but ‘groups’. (read what you wrote!)
For the profile landing tab, see this codex page.For groups, you can try this snippet. This let you define a different landing tab for each of your groups (not profile, ok ?). 😉
function bpfr_custom_group_default_tab($default_tab){ /** * class_exists() is recommanded to avoid problems during updates * or when Groups Component is deactivated */ if ( class_exists( 'BP_Group_Extension' ) ) : // $group=groups_get_current_group();//get the current group if(empty($group)) return $default_tab; switch($group->slug){ case 'kill-bill': // group name (use slug format) $default_tab='forum'; break; case 'groupe-2014': $default_tab='members'; break; default: $default_tab='home';// the original default landing tab break; } return $default_tab; endif; // end if ( class_exists( 'BP_Group_Extension' ) ) } add_filter('bp_groups_default_extension','bpfr_custom_group_default_tab');July 11, 2016 at 5:50 pm #256489In reply to: Change ‘Show all X comments’ limit
danbp
ParticipantGlobal.js is related to BP Default theme which is no more used since 1.9.
The “new” js you can check for comment count is \buddypress\bp-templates\bp-legacy\js\buddypress.js:667I don’t know how the default 5 count is set before firing Show all X comments link. But i haven’t read very attentively the whole js file.
If your goal is to gain some place on activity feeds, you may use a show/hide comment button ?
function add_comment_hide_show() { ?> <style> .single-group .activity-comments ul{display: none;} </style> <script type="text/javascript"> jQuery(function($) { setInterval(function() { $('.activity-meta').each(function() { if( !$(this).find('.show-comments').length ){ var html = '<a href="#" class="button bp-primary-action show-comments">Show/Hide Comments</a>'; $(this).find('.button.acomment-reply').after(html); } }); }, 500); $('body').on('click', '.show-comments', function(e) { e.preventDefault(); var obj = $(this).closest('.activity-content').next('.activity-comments').find('ul'); obj.slideToggle(); return false; }); }); </script> <?php } add_action( 'wp_footer', 'add_comment_hide_show' );Or if you want to limit the number of comment a member can leave on activities, BPDEVEL has a premium plugin called BP Rate Limit User Activity which can do that.
On Trac, some very old tickets about comments: #2768, #1870
Perhaps @dcavins can tell you more about this ?
July 11, 2016 at 5:28 pm #256488In reply to: How to hide profile menu items from other users
marcono
Participant‘danbp’ your codes work great!
One thing, though, since I removed the ‘home’ item in groups, now if I create a private group or click on a public group icon, the group page will not be available!
I think it is because the ‘home’ item has remained as the default page for the group pages!? I changed my profile default page with ‘define(‘BP_DEFAULT_COMPONENT’, ‘profile’ );’ but it seems for changing group default tab story is different, so I used code suggested here: https://buddypress.org/support/topic/changing-group-tab-display-defaults/But still no success!?
July 11, 2016 at 3:40 pm #256480David Cavins
KeymasterHi there-
Yes, 2.6.1 (and 2.6.1.1) have a conflict with BP Group Hierarchy. The problem is caused by the addition of the autoloader check in
bp-loader.phpbecause BPGH instantiates its class before BP knows if the groups component is active or not. The short term fix is, unhappily, to changebp-loader.php. Comment out the line that readsreturn(add a//beforereturn) here:
https://github.com/buddypress/BuddyPress/blob/master/src/bp-loader.php#L621 -
AuthorSearch Results