March 11, 2019 at 3:39 pm #9829
is there anyway to get rid of the never active tag that displays in the search results for the users? Ideally it would be replaced with the extended profile summary. Is this possible? How would I do this?March 11, 2019 at 5:47 pm #9830
The search results are displayed by BuddyPress in its Members directory, so the only way to change their display is to modify the BuddyPress Members directory template, see the procedure E) in:March 11, 2019 at 8:36 pm #9831
I managed to get rid of the last active tag but can’t seem to add a summary. I see where I need to add it but i’m not sure how. also do I need the shortcode for the custom field titled summary if that’s the field I want to display in the search results?March 12, 2019 at 10:03 am #9832
I guess you modified the file members-loop.php to remove the last activity time. In the same file, look for this code:
<?php /*** * If you want to show specific profile fields here you can, * but it'll add an extra query for each member in the loop * (only one regardless of the number of fields you show): * * bp_member_profile_data( 'field=the field name' ); */ ?>
that explains how to add specific profile fields. After the comment, add:
bp_member_profile_data( 'field=name_of_your_field' );
to display that field’s value (add one line for each field you wish to display).March 12, 2019 at 8:54 pm #9833
Yes I saw that. But. i’m having trouble getting the summary. where do I find the shortcodes/metadata for custom fields?March 12, 2019 at 10:20 pm #9834
If you wish to print the value of a profile field, you only need the name of that field. If the field name is ‘First Language’, you need:
bp_member_profile_data( 'field=First Language' );
Did you try that?March 12, 2019 at 11:37 pm #9835
bp_member_profile_data(‘field=Summary ‘ );
for the field ‘Summary’.
doesn’t workMarch 13, 2019 at 10:57 am #9836
If a user didn’t fill the field ‘Summary’, nothing is displayed for that user, so make sure the field has a value or you won’t see anything printed out.
Then, to make sure you added the code in the right place, add an ‘echo’ statement to print something:
<?php /*** * If you want to show specific profile fields here you can, * but it'll add an extra query for each member in the loop * (only one regardless of the number of fields you show): * * bp_member_profile_data( 'field=the field name' ); */ echo 'the value of Summary is: '; bp_member_profile_data( 'field=Summary' ); ?>
You should see at least the output of the ‘echo’ statement.March 13, 2019 at 7:00 pm #9837
No luck. search here and try for yourself. all members have summaries. search ‘publishing’ and the test user should show up with their summary. the user shows up but not the summary. look here.March 14, 2019 at 10:27 am #9838
If you send me a WP admin and an FTP access, I’ll take a look and I’ll try to fix it. You can send that info privately using my Contact page.March 25, 2019 at 7:39 pm #9847
can i still do this?March 26, 2019 at 10:24 am #9848
Yes, of course!