get rid of never active tag

Home Forums BP Profile Search Forum get rid of never active tag

This topic contains 11 replies, has 2 voices, and was last updated by  andrea 2 months, 3 weeks ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #9829 Reply

    jake

    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?

    #9830 Reply

    andrea
    Keymaster

    Hello Jake,

    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:

    https://dontdream.it/bp-profile-search/custom-directories/

    #9831 Reply

    jake

    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?

    #9832 Reply

    andrea
    Keymaster

    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).

    #9833 Reply

    jake

    Yes I saw that. But. i’m having trouble getting the summary. where do I find the shortcodes/metadata for custom fields?

    #9834 Reply

    andrea
    Keymaster

    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?

    #9835 Reply

    jake

    just tried

    bp_member_profile_data(‘field=Summary ‘ );

    for the field ‘Summary’.

    doesn’t work

    #9836 Reply

    andrea
    Keymaster

    Hi Jake,

    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.

    #9837 Reply

    jake

    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.

    http://www.bwa.org/find-a-writer/

    #9838 Reply

    andrea
    Keymaster

    Hi Jake,

    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.

    #9847 Reply

    jake

    can i still do this?

    #9848 Reply

    andrea
    Keymaster

    Yes, of course!

Viewing 12 posts - 1 through 12 (of 12 total)
Reply To: get rid of never active tag
Your information: