-
atburi replied to the topic Two different functions that display member profile field data in the forum How-to & Troubleshooting 11 years, 5 months ago
It appears to have something to do with the user id being set in bp_has_members() and passed on to the other functions.
If the displayed member does have friend connections and a user id is set in the bp_has_members() loop, then that ID gets passed to the bp_get_member_profile_data() and xprofile_get_field_data() functions that I’m using to…[Read more]
-
atburi replied to the topic [Resolved] Returning friend connections of the current profile being viewed in the forum How-to & Troubleshooting 11 years, 5 months ago
Update:
'user_id' => bp_displayed_user_id(),
This works so far, and doesn’t use the global $bp;
-
atburi started the topic [Resolved] Returning friend connections of the current profile being viewed in the forum How-to & Troubleshooting 11 years, 5 months ago
[WP 3.5.2 / BP 1.8-beta1 / custom theme]
I am using the code below to display friend connections the member whose profile is being viewed:
<?php
global $bp;
$args = array(
'user_id' => $bp->displayed_user->id,
'max' => '30',
'type' => 'random'
);if ( bp_has_members( $args ) ) : ?>
<ul id="members-list" class="item-list inline…[Read more]
-
atburi started the topic Two different functions that display member profile field data in the forum How-to & Troubleshooting 11 years, 5 months ago
[WP 3.5.2 / BP 1.8-beta1 / custom theme]
Hi Everyone,What exactly is the difference is between:
xprofile_get_field_data() & bp_get_member_profile_data()
For instance, I have a customized member/home/profile/profile-loop page and early on in the code for that page I’m running a bp_has_members() loop to show friend connections of the displayed…[Read more]
-
atburi replied to the topic [Resolved] Populating BP Profile Loop for author of a WP Post in the forum How-to & Troubleshooting 11 years, 5 months ago
Thanks Hugo, all makes sense….
I’ll leave it that and mark as resolved!
-
atburi replied to the topic [Resolved] Populating BP Profile Loop for author of a WP Post in the forum How-to & Troubleshooting 11 years, 5 months ago
Thanks for the response, @hnla
Indeed, that works; just wasn’t sure how to properly code inside a php bracket like that.
I’m running the member’s profile loop in the sidebar of the single post page, so this would be outside the single post content loop. However, also in the side bar I use the function:
bp_core_get_userlink( $post->post_author…
[Read more] -
atburi replied to the topic [Resolved] Populating BP Profile Loop for author of a WP Post in the forum How-to & Troubleshooting 11 years, 5 months ago
This worked 🙂
<?php if ( bp_has_profile( array( 'user_id' => $user_id ) ) ) : ?>
Is this the best solution?
-
atburi started the topic [Resolved] Populating BP Profile Loop for author of a WP Post in the forum How-to & Troubleshooting 11 years, 5 months ago
Hi everyone,
I would like to use the
bp_has_profile()
loop to run through the profile fields of authors on my WordPress single.php page.I know it goes something like:
<?php if ( bp_has_profile( 'user_id=10' ) ) : ?> .....
But my issues is finding the right code to dynamically generate the user ID of the current WP post. I’ve tried using
<…
[Read more] -
atburi replied to the topic [Resolved] BP1.8-beta1 & WP3.6-beta4–Blank frontend when using BP default theme in the forum Installing BuddyPress 11 years, 5 months ago
Hi 4ella,
With my issue, I was getting the white screens on the backend. I forget how I fixed it, but it turned out to be a problem with my plugins/theme files and not with the latest versions of WP or BP. I would disable all your plugins one by one and see if that helps. If you are running a development version of your site offline, trying…[Read more]
@aburi
Active 9 years, 2 months ago