The file path should be wp-content/plugins/bp-custom.php. If that doesn’t work for you then there’s likely a problem elsewhere.
I am looking at the thread “Adding profile fields to members directory”
https://buddypress.org/support/topic/adding-profile-fields-to-members-directory/
You wrote:
There’s 2 ways of doing this.
1. You could modify the members-loop template (see the BuddyPress Template Hierarchy for details on how that’s done). See here. You would just add bp_member_profile_data( ‘field=the field name here’ ); to the template.
2. Add this to your theme’s functions.php file:
function add_info_to_members_loop() {
echo bp_get_member_profile_data( ‘field=the field name here’ );
}
add_action( ‘bp_directory_members_item’, ‘add_info_to_members_loop’ );
Which template are you referring to in 1.?
can both code snippets be placed either in functions.php or bp-custom.php?
Which template are you referring to in 1.?
Check out the Template Hierarchy article. The file you’d need to copy and then modify is buddypress/members/members-loop.php.
can both code snippets be placed either in functions.php or bp-custom.php?
2 can but 1 isn’t a code snippet (you’re copying and then modifying a file).
Thanks, I have read the page about Template Hierarchy, can see this is very complex, at least to me.
I looked to the buddypress directory which looks different:
wp-content > plugins < buddypress > bp-members > ?
members_loop.php does not exist, is this aam I in the wrong directory?
I have tried to ad a buddypress.php file to both my theme and child theme directory, but this will prevent my site from loading?
You can find all of the templates in a buddypress folder here: bp-templates/bp-legacy.
Step 1. Copy the buddypress folder to your theme. You should then have something that looks like this: wp-content/themes/your-theme/buddypress
Step 2. Edit the files inside the buddypress folder.
Copy, and at the same time leave the original buddypress folder under plugins?
You shouldn’t modify the original plugin files.
I mean, the buddypress folder in bp-templates/bp-legacy
Thanks, now I think I understand…
copying the buddypress folder containing the members-loop.php to my child theme leaves my page blank.
And now the folder can’t be deleted from the child theme…
“buddypress” could not be deleted, because an error (22126) occurred.
Hmmm, probably an browser error
How are you trying to delete the buddypress folder?
First I tried Textwrangler, it diden’t work, then I managed to delete the folder with FileZilla