Forum Replies Created
-
That’s probably the issue, you don’t have any of the BP Components enabled. I’m not sure but I don’t think you will get a new member activity entry unless you have Extended Profiles enabled.
It’s a bit strange that from this screenshot you are showing groups as not enabled but in your activity you have groups showing as being created though.
That’s really quite odd, which BP Components do you have active?
So it’s the activity not posting that’s the issue not the filters. I think in the first instance I’d deactivate all other plugins, switch to a default theme such as 2017 and add another user, see if that shows up in activity. I’d also check if you’ve set up any filters for the activity loop that might exclude that content.
For new posts and comments you’d need to check that site tracking was enabled in the BuddyPress Component settings.
In reply to: Include multiple xProfile fields in members loopI’ve editted my original post with added code t remove the current user id from the list.
I don’t see an issue with these filters, in order for them to work you would need some of these activity types in your activity stream, and there arn’t, so none would be found.
In reply to: Include multiple xProfile fields in members loopok, try replacing that line with the following:
$custom_ids = array_merge( $custom_ids, $wpdb->get_col( $query ) );In reply to: Include multiple xProfile fields in members loopMaybe it’s the array_push that’s not working, just for testing try replacing:
$custom_ids = array_push( $custom_ids, $wpdb->get_col( $query ) );With the original@
$custom_ids = $wpdb->get_col( $query );and keep the query to only dogs.
That should return the same as the original code, but it would only work with one query pair.
In reply to: Include multiple xProfile fields in members loopI guess the first thing to try is to take it back to the basic query and see if that works the same as the original code:
<?php if ( bp_has_members( my_custom_ids( array( 'dogs' => 'poodles' ) ) ) ) : ?>In reply to: ERROR: Your topic cannot be created at this time.Are you using Akismet or some other spam blocking plugin? Also Topics are forums related, BuddyPress does not include forums, for those you’d be better off asking on that plugins forums.
In reply to: Include multiple xProfile fields in members loopYou’d have to change the code to accept an array, for example:
<?php if ( bp_has_members( my_custom_ids( array( 'dogs' => 'poodles', 'birds' => 'parrot' ) ) ) ) : ?>Then for your function you’d do something like this:
function my_custom_ids( $field_array = array() ) { if ( empty( $field_array ) ) return ''; global $wpdb; $custom_ids = array(); foreach( $field_array as $field_name => $field_value ) { $field_id = xprofile_get_field_id_from_name( $field_name ); if ( !empty( $field_id ) ) $query = "SELECT user_id FROM " . $wpdb->prefix . "bp_xprofile_data WHERE field_id = " . $field_id; else return ''; if ( $field_value != '' ) $query .= " AND value LIKE '%" . $field_value . "%'"; /* LIKE is slow. If you're sure the value has not been serialized, you can do this: $query .= " AND value = '" . $field_value . "'"; */ $custom_ids = array_merge( $custom_ids, $wpdb->get_col( $query ) ); } $user_id = get_current_user_id(); if ( in_array( $user_id, $custom_ids ) ) unset( $custom_ids[$user_id] ); if ( !empty( $custom_ids ) ) { // convert the array to a csv string $custom_ids_str = 'include=' . implode(",", $custom_ids); return $custom_ids_str; } else return ''; }Not tested it but that’s the way you’d do it.
This sounds like a Learnpress issue so you should raise it with the developers of that plugin.
In reply to: Groups add new 404 Not FoundWhich solutions did you try?
In reply to: Cannot invite members to grouGot a screenshot?
I’ve deactivate all other plugins, switch to the 2017 theme and retest.
In reply to: Change the media button on the profileHi there, BuddyPress does not come with a Media button, that’s added by another plugin, you should ask that developer for the best way to do this.
In reply to: Show list of xProfile Field values?Sorry I don’t.
The code to get the xprofile field data for a member is as follows:
$field_data = xprofile_get_field( $field_id, $user_id, true ); $field_value = $value->data->value;One thing you could do as a first step is to add these fields to the standard members loop:
add_action( 'bp_directory_members_item', 'bpex_add_profile_field_data' ); function bpex_add_profile_field_data() { $field_data = xprofile_get_field( $field_id, bp_member_user_id(), true ); $field_value = $value->data->value; echo '<span>' . $field_value . '</span>'; }You’d need to supply the $field_id for this to work.
That would obviously add this data to all the members directory view which may not be what you want but it’s a start.
In reply to: Show list of xProfile Field values?One option would be to setup a members list and filter the members based on if they have certain profile fields set then display the extra profile fields in the loop.
In reply to: Show list of xProfile Field values?I’ve created a group member list shortcode in the same plugin that allows extra profile fields to be displayed as part of a group member list, don’t suppose all the members you want to display belong to the same group?
In reply to: Show list of xProfile Field values?Actually it might not work. The issue is that you have to be able to pass the user_id to the shortcode. On BuddyPress pages you can use the BP displayed user id, on posts you can use the post author user_id.
alternaive typical use would be to manually code the user id:
[bpps_profile_field option="Two" field="your-field" user_id="1"]In reply to: Show list of xProfile Field values?You can add shortcodes to display the members profile fields and links to profile using BP Profile Shortcodes Extra. I don’t think you can set a condition that if one profile field is filled in then so should the other one by default but you could write some code to carry out that check an reject the change if the appropriate field is not filled in.
You can turn off user registrations in Settings>>General then I believe you can add the Invite Anyone plugin to allow members to invite others, you’d then need to add the invite anyone widget in a way that it only displays for admin. It’s doable, with a bit of work.
In reply to: My request doesn’t workedThis usually happens if a word used in your post has triggered our anti-spam system.
In reply to: Community menu links and pages problemThose feature do not look like they were added by BuddyPress, you probably have a plugin creating it, try asking that plugins developer.
In reply to: Image not saving in xprofile textarea fieldYou can report bugs via Trac: https://buddypress.trac.wordpress.org/
In reply to: Ho to style a $field_data in buddypress functionHi there,
If I was looking to do this I’d overload
members/members-loop.phpand add the styling there. bp_member_name only returns the name of the member, not an element that you can style. In the members-loop it’s used to create a link to the members profile and you could either apply the styling to that.An alternative would be to simply add this as css styling such as:
.member-name { font-weight: 400; }In reply to: Prevent Spam RegistrationsThe best defence I have found is using https://wordpress.org/plugins/simple-google-recaptcha/ this seems to remove most of them, there’s also https://wordpress.org/plugins/registration-honeypot/