This topic has 8 replies, 3 voices, and was last updated 10 years by Abe.

  • Author
  • #13953
     Jonbie
    Participant

    On sign-up to my website, users are asked there account type, business, radio station etc (bout 10 in total).
    I would like way where another users can see what type of account they hve without hve to red the bio section in there profile.

    I would luv to be able to have different online colors (blue is default) for each account type or have a stroke/border round each account type in different colors, but this seems to complicated?

    if this is not possible would it be possible to have the account type beside the users name?

    Thanks,

    Jon

    Attachments:
    You must be logged in to view attached files.
    #14173
     Abe
    Keymaster

    Hi, You can show a specific field value in the profile header by editing kleo\buddypress\members\single\member-header.php and adding bellow code where you want it to show. Change the field name in the example:
    <?php echo bp_get_profile_field_data(array('field' => 'Birthday'));?>

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    ---
    @ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.

    #14174
     Abe
    Keymaster

    Any styling or other custom changes implies custom work and you should hire a developer to help you if you do not have PHP/HTML/CSS knowledge

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    ---
    @ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.

    #14375
     Jonbie
    Participant

    Hi Abe,

    I am using this code to place the profile field “Type of account” beside the users name in the h1 title of all buddypress pages.

    <div id=’member_profile’>
    <div class=’profile_fields’>Category: <span><?php echo bp_get_profile_field_data(array(‘Type of account’ => ‘Type of account’));?></span></div>
    </div>
    <?php

    i added it to under

    <div id=”item-header-content” <?php if (isset($_COOKIE[‘bp-profile-header’]) && $_COOKIE[‘bp-profile-header’] == ‘small’) {echo ‘style=”display:none;”‘;} ?>>

    but it doesnt seem to be working, am i adding it to wrong place? is the code ok?

    Thanks for the help.

    #14572
     Jonbie
    Participant

    Hi Abe,

    Sorry for the delay in getting back to you. I couldnt get that code to work unfortunately?

    #14673
     Abe
    Keymaster

    What is the code you added? You should change “Birthday” with your own field name and it should display

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    ---
    @ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.

    #14835
     Jonbie
    Participant

    Hi Abe,

    Thanks for the code Abe.

    I am having the issue now on where to place it. The h1 title on the buddypress users page is the users name. I would like to add to profile field beside the users name, on the same line right beside it but i have no idea which file to add it too?

    Any idea where the file is that grabs the users name and places it in the h1 title?

    Thanks

    #14840
     sharmstr
    Moderator

    Correct me if I’m wrong Abe…

    You can edit the general-before-wrap.php file (put it in your child theme). You’ll see the h1 tags. Before that, you’ll have to do a conditional check to make sure its a buddypress profile page. I cant recall the conditional check for that off the top of my head.

    something like this

    if (buddypress profile)
    $addextra = (use your code to set this to extra info you want)

    echo ‘<h1 class=”page-tite”>’ . kelo_title() . $addextra . ‘</h1>’;

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #14902
     Abe
    Keymaster

    Hi, If you want to display it like in the image attached, you need to copy the template located in kleo\buddypress\members\single\member-header.php to your child theme following the same folder stucture.
    That template shows only on users profile page so you don’t need any conditions

    https://cdn.seventhqueen.com/sq-support/wp-content/uploads/2014/03/username-profile-page.jpg

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    ---
    @ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.

Viewing 9 posts - 1 through 9 (of 9 total)

The forum ‘KLEO’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?