Forum Replies Created
-
In reply to: Need help with Custom Code
imo, It’s not clear what you’re trying to do.
On a ‘single activity page’ – you mean the profile activity page for a specific member ?And on that page you want to display, in a sidebar, the 20 most recent updates from all users ?
In your code, you’re only looking for updates that include an image [bpfb_images]
So you only want the 20 most recent updates from all members that include an image ?
If so, you’d be better off writing a custom query. Then you won’t have to do all that string parsing.In reply to: [Resolved] xprofile_data_after_save hook not workingTo test if the hook works, use wp_redirect instead of die and send it to another site like google.
In reply to: Custom groups loop with groups metaMaybe something like this – untested:
`
$group_ids = $wpdb->get_var(“SELECT id FROM groups_groupmets WHERE meta_key = ‘group-country’ AND meta_value = ‘Russia'”);foreach ( $group_ids as $group_id ) {
$group_ids_str[] = $group_id->id”;
}
$theIncludeString = implode (‘,’, $group_ids_str);if( !empty($theIncludeString) ) // build args and start loop
else … ?
`In reply to: bp profile menu adding more menu itemsWrap your code in back ticks to show it here.
In reply to: BuddyPress & Membership Site integrationStart with this plugin
In reply to: Problem deleting user AND blogThere is a hook …
`do_action( ‘bp_members_delete_account_after_submit’ );`
in /bp-default/members/single/settings/delete-account.phpYou could quite easily use that hook and write a function that will delete the user’s blogs & posts.
And that way you could leave the /wp-admin/admin.php?page=bp-settings to Yes to allow users to delete their account.In reply to: Searching BuddyPress.Org – HOW?Yes it is frustrating.
And a known issue which makes the continuing presence of the search box rather perverse.Why not remove it?
Or replace it with a google search box ?In reply to: Problem deleting user AND blog>A user can delete his account
That’s a BP item.
You can change the settings here and have them contact the site admin to delete their account
/wp-admin/admin.php?page=bp-settingsThen you can use wp-admin/users.php to delete the user and all their blogs & posts
If you want users to be able to delete their own accounts and have all their blogs & posts deleted at the same time, you’ll have to write some custom code.
In reply to: Is this a bug?Where are you trying to get the Full Names to show up ?
I think $members_template is for use inside the members loop.
Have you looked at the plugins/buddypress/bp-xprofile code ?
> However, in order to get full names showing up I’ve been trying to use ‘bp_get_member_profile_data’. It wasn’t working,
Post the snippet of your attempt and tell us where you called it. And your BP version.
Does it have to be a profile field?
Or could it just be displayed on the profile page?If you need to save the info into a custom profile field, it’s a little more work.
Either way – use the same process you used for your bp_album ‘system’.
Start by looking thru
/plugins/buddypress/bp-members
and
/plugins/buddypress/bp-xprofilefor hooks and filters and use them in profile theme files.
In reply to: search resultsYou want a build a Buddypress site that nevers shows up in public search results ?
I don’t think that’s possible with any website.
In reply to: Roles and Capabilities>Does BP use the built-in WP roles/caps system?
Yes.
edit: oops, thanks below, modemlooper
You can create plugins that do things, such as custom post types, that use the WP roles/caps system.
In reply to: 3 plugins for beginnersJust curious…
Do you really need this function
`if ( !function_exists( ‘bp_core_install’ ) ) { … `
if you’re using a loader file ?In reply to: [SOLVED] BuddyPress Profile InformationLook thru your theme files:
profile – all files
functions.php
bp-custom.php (if it exists it’ll be in the plugins folder )
style.cssIn reply to: [SOLVED] BuddyPress Profile InformationAre you sure that code is from your theme file and not the default buddypress theme ?
There is something in your theme that is causing this output:
`<a href="http://stonerapproved.com/members/?s=Brandon" rel=”nofollow”>Brandon
`
Probably easiest to contact the theme creator and show them this thread. v
In reply to: [SOLVED] BuddyPress Profile InformationThis is probably a theme problem.
Look at the generated code – you are creating a double href and have other issues
Can you post your source code for this page ?
It should be in /members/single/profile/profile-loop.phpIn reply to: custom post type in buddypress activityHere’s some info, but it requires php skills to implement:
https://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/display-custom-post-types-in-activity-feed/In reply to: Activity Stream For Groups ONLY?Read this:
https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-activity-stream-loop/Note the scope parameter which accepts the argument ‘groups’
In reply to: [Resolved] Links don’t work on new installAre you using an apache server ?
Do you have a htaccess file ?
Here are a couple of links that include info re htaccess:
https://codex.wordpress.org/Using_Permalinks
http://www.netmagazine.com/tutorials/protect-your-wordpress-site-htaccessTry:
`
if ( ( $user->roles[0] != ‘subscriber’ ) && ( $user->roles[0] != ‘customer’ ) ) : ?>
`imho: this is much better
http://wp-events-plugin.com/You can show info from another database simply by calling that database and displaying the results in any format you wish.
Integrating those results into the activity stream will be a bit more difficult.
It would be easier to show them as a separate listing.I’ve used separate zipcode databases for doing radial zipcode searches and it works fine.
Try this:
<?php echo get_author_posts_url( $bp->displayed_user->id ); ?>In reply to: [Solved] Get list of unread private messagesSee bp_has_message_threads() for type param. It defaults to ‘all’.
You don’t need to dirty hardcode anything – you just need (maybe) to write a custom query and call it from a theme file.
read/unread is stored in wp_bp_messages_recipientsGood luck
In reply to: [Solved] Get list of unread private messagesDid you look at the codex?
https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-private-messages-loop-bp_has_message_threads/Try this to start your loop
``
I’m not sure if ‘type=unread’ is valid.
bp_message_thread_has_unread() returns true or false
So you can use it in your loop to decide whether to proceed.