Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'profile fields'

Viewing 25 results - 3,101 through 3,125 (of 3,593 total)
  • Author
    Search Results
  • #61791
    designodyssey
    Participant

    @JJJ

    First, is it jjj or JJJ?

    Second, is there some way to use the usermeta solution for groups?

    Also, I want to change the display of everything (dropdowns, menus, labels, etc.) to account for the different user types (e.g. teachers, students, parents). That would also need to be the case for groups (e.g. classrooms, schools, departments). How would you suggest going about this?

    Thanks

    #61785
    Nick Watson
    Participant

    bp_the_profile_field_value displays ALL of the values of the fields within the group, and

    bp_the_profile_field_name displays ALL of the names of the fields within the group.

    I tried what you said with the <?php if ( bp_the_profile_field_name() == ‘color’ ) {

    but that still just continues to display ALL of the fields. (And yes I changed the ‘color’ to the proper field name)

    Anyone have ideas on how to get a profile fields output to display a picture instead of the text?

    #61737

    Newer versions of BP along with newer templates and MU have solved this by moving those hooks and actions into the template, and BP hijacks the registration before it happens.

    It’s happening because of an outdated theme arrangement. I’m going through something similar also at the moment and will be tracking this down shortly.

    @wekko, the reason those fields aren’t entered right away is because a registered user isn’t an actual activated user yet. They need to click the link or be activated by the site admin in order to actually get entered into the user tables. In either case, that xprofile data is moved into the xprofile tables when the activation occurs, not when they register.

    #61735
    wekko
    Participant

    I found the answer. It’s not Buddypress, it’s WordPress MU. See: https://mu.wordpress.org/forums/topic/15324 . Apparently, wp-activate.php doesn’t load the Buddypress login including the hooks. Weird thing it doesn’t happen to everyone..

    #61685
    Tracedef
    Participant

    Do follow is also a great way to encourage users to create and fill out a profile, specifically if you create custom fields for their “websites” in their profile. Spam registrations are already a major issue ( at least for us ) so that isn’t much of a deterrent for us at least.

    #61674
    Boone Gorges
    Keymaster

    The code that I listed will not work as is. You have to make sure that you fill in the correct filenames for images, the correct desired values for profile fields, and the correct field names. Also it looks like I messed up and forgot at least one parenthesis. That’s why I said you’d need to tweak it. It should give you an idea of which functions to use, though.

    #61662
    danbpfr
    Participant

    You can search here for answers :

    https://trac.buddypress.org/report

    #61654
    wekko
    Participant

    Well, that makes sense. Still, if it’s a bug and it’s fixed in newer versions…someone should know about it right? :)

    #61640
    Boone Gorges
    Keymaster

    In [your-bp-theme-dir]/members/single/profile/profile-loop.php, you’ll see a profile loop beginning while ( bp_profile_fields() ) : bp_the_profile_field();. Inside of that profile loop you will be able to use various profile functions to test values. For instance,

    <?php if ( bp_the_profile_field_name() == 'color' ) {
    if ( bp_the_profile_field_value() == 'red' )
    echo '<img src="redbadge.png" />';
    if ( bp_the_profile_field_value() == 'green'
    echo '<img src="greenbadge.png" />';
    // etc.
    }
    ?>

    I have not tested this but it should work fine with some tweaking.

    Your issue with appearance is a CSS thing, most likely that the ul elements are set to display: inline. Try setting them to display: block.

    #61633
    peterverkooijen
    Participant

    There was a new blunt solution here. Apparently having a couple of required custom profile fields also cuts down spam.

    #61623
    Paul Wong-Gibbs
    Keymaster

    To be honest you aren’t going to get much/any support based on bugs in previous versions of BuddyPress as we may have fixed them in the more recent versions.

    #61462
    Andy Peatling
    Keymaster

    Can you post this in a ticket please?

    #61457
    grosbouff
    Participant

    Ok, I founded out :

    if ( bp_has_profile() ) {

    while ( bp_profile_groups() ) : bp_the_profile_group();

    global $group;

    $one_group = array();

    $one_group[‘id’] = $group->id;

    $one_group[‘name’] = $group->name;

    $groups[ $group->id ] = $one_group;

    //if ( bp_profile_group_has_fields() ) {

    while ( bp_profile_fields() ) : bp_the_profile_field();

    //if ( bp_field_has_data() ) {

    global $field;

    $one_field = array();

    $one_field[‘id’] = $field->id;

    $one_field[‘name’] = $field->name;

    $fields[] = $one_field;

    //}

    endwhile;

    //}

    endwhile;

    }

    Hope that it’s ok to comment those lines…

    #61456
    grosbouff
    Participant

    Seems this has something to do with function has_fields() :

    function has_fields() {

    $has_data = false;

    for ( $i = 0; $i < count( $this->group->fields ); $i++ ) {

    $field = &$this->group->fields[$i];

    if ( $field->data->value != null ) {

    $has_data = true;

    }

    }

    if ( $has_data )

    return true;

    return false;

    }

    print_r($field) returns

    teststdClass Object ( [id] => 1 [name] => Name [type] => textbox [group_id] => 1 ) stdClass Object ( [id] => 2 [name] => Name [type] => textbox [group_id] => 1 ) stdClass Object ( [id] => 3 [name] => First Name [type] => textbox [group_id] => 1 ) stdClass Object ( [id] => 4 [name] => Both Names [type] => textbox [group_id] => 1 )

    print_r($field->data) returns FALSE…

    #61303
    Nick Watson
    Participant

    Oh yeah, I know that’s there, but that is only the Nickname thing from the wordpress.

    I was wondering if there as anyway to edit the other fields (stored by wordpress) on the profile page.

    #61267
    Brajesh Singh
    Participant

    It is already there.

    But you may not edit the Fields which are stored by wordpress(If your User had registered before activating buddypress). Only Buddypress xprofile fields can be edited from profile page.

    Under profile link, you will see edit profile which will allow you to change the basic details(xprofile fields).

    Under settings->general you can change email/password.

    #61130
    Paul Wong-Gibbs
    Keymaster

    The only thing you might want to look into is to show/hide specific xprofile fields for different groups. That’s more advanced and requires some new code to be written by someone ;)

    This is possible without too much effort, I have recently done it for a client. I considered using usermeta to indicate the type but it worked better for my client’s site to have it is an xprofile field. I wrote some code to not display or permit changes to it after registration, too.

    #61123
    Anonymous User 96400
    Inactive

    Bowe, I’d store user types as usermeta. Might be a bit more work code-wise, but I think more flexible.

    Showing certain profile fields by user-type with jQuery is just your basic conditional stuff. If this user-type is selected, then show these fields, if another type is selected show some other fields.

    #61121
    Bowe
    Participant

    I don’t have a solution for all your problems but assigning different “user” types to your site is easy:

    – Create a xprofile field in your BuddyPress admin. For example: What kind of user are you:

    a. Swimmer

    b. Skater

    c. Surfer

    – Install the BP Member filter plugin: https://buddypress.org/forums/topic/bp-member-filter

    – Users can now filter members on the member directory page to find certain usertypes

    The only thing you might want to look into is to show/hide specific xprofile fields for different groups. That’s more advanced and requires some new code to be written by someone ;)

    Good luck!

    edit: Maybe if you combine both tips from Boris and me you just got your solution ;)

    ps: I’m interested in the jquery profile fields stuff as well.. sounds handy!

    #61120
    Anonymous User 96400
    Inactive

    @psyber

    You can just add to the existing registration process via the available hooks. So basically you add a dropdown field where the user has to select an option. Then you use a bit of jQueryness to display the various profile fields you want that user-type to fill in. I’ve done something similar for group types. Took about 20 minutes to code, so it’s not really hard :)

    #60995

    In reply to: BP Member Filter

    @katendarcy

    This plugin doesn’t perform logic searches within fields, but it does allow you to search for criteria in any xprofile field and any combination of them (except checkboxes at the moment.)

    @michaelesenwasser, not yet that I know of.

    #60723
    Tom
    Participant

    Yup- just as I thought.. in members-loop.php find-

    <?php bp_the_site_member_last_active() ?>

    and change to-

    <?php echo bp_custom_get_member_list_xprofile_data('Gender') ?>

    Where “Gender” is the name of the profile field you wish to display.

    #60722
    Tom
    Participant

    Threads been quite helpful for me so far..

    I’m using Jet random members widget on the ‘members’ page and I’ve managed to get one of my profile fields to display there now, rather than a random field.

    Here’s what I done…

    In /directories/members/index.php find-

    <?php bp_the_site_member_random_profile_data() ?>

    and replace with-

    <?php echo bp_custom_get_member_list_xprofile_data('Gender') ?>

    where “Gender” is the name of the field you wish to display.

    Then in bp-custom.php (in your plugins folder), add this:

    //To add custom profile fiels to random members widget //
    function custom_xprofile( $field ) {
    echo bp_custom_get_member_list_xprofile_data( $field );
    }
    function bp_custom_get_member_list_xprofile_data( $field ) {
    global $site_members_template;
    return xprofile_get_field_data( $field, $site_members_template->member->id );
    }

    I’m working on a few other tweaks now to try adding this custom field to the actual member listing part of the page now and I imagine it will work in the same sort of way. I’ll keep you posted.

    #60617

    In reply to: Moderate members

    Tom
    Participant

    Seems that only fixed the admin panel problem.

    However it’s throwing up errors on the front end now.

    To be honest I think this plugin is maybe outdated.

    I’ll list here my site’s configuration, and what errors I’m getting in-case anyone fancies making this plugin work as it should.

    OK.. Groups and Blogs are disabled site-wide (Except for the main site blog).

    The setting “Allow new registrations” is set to “Only user account can be created.”

    And “Registration notification” set to “Yes”

    1st problem (As previously mentioned in this thread)… When I go to the admin panel and try to edit the options for the plugin, and hit save, it throws up the errors that I posted here:

    https://buddypress.org/forums/topic/moderate-members?replies=1#post-33514

    I managed to get rid of those errors by doing as mentioned here:

    https://buddypress.org/forums/topic/moderate-members?replies=1#post-33517

    However… it turns out that was not a fix for the plugin, so I reverted the file back to original state.

    OK, I couldn’t edit the emails that would be sent out due to those errors, but I could of worked around that (editing within the file itself)… so I continued to the next step, which was to try and create a new account, to see if the plugin actually done what it’s supposed to.

    After entering all my required fields, and hitting the submit button, I was taken to the upload avatar page. I was also shown the “Check your email address for your activation email” notice. Also, at the top of the page these errors appeared:

    Warning: implode() [function.implode]: Invalid arguments passed in /home2/puezq/public_html/mysite.com/v2/wp-content/plugins/bp-registration-options/bp-registration-options.php on line 639

    Warning: implode() [function.implode]: Invalid arguments passed in /home2/puezq/public_html/mysite.com/v2/wp-content/plugins/bp-registration-options/bp-registration-options.php on line 642

    Since I know only very little php, I had a look to see what those lines were in the plugin php file, but done nothing with them. Here are those lines:

    639 $bp_groups_str = implode(",", $bp_groups);

    642 $bp_blogs_str = implode(",", $bp_blogs);

    So I’m guessing these errors are showing because I have blogs and groups disabled on the site?

    However the plugin php file is full of terms relating to blogs and groups, so I saw no point just removing those lines from the file as other errors would appear from somewhere… surely?

    Anyway, to see what happened next- I then uploaded an avatar, successfully. The errors at the top of the page disappeared when it was uploaded.

    I then clicked on the activation link in the email I received, and logged into the site. I was able to EDIT my profile and browse the site pages normally, but not able to view member profiles, my own public profile, or even view the members search page.

    I then received an email saying there was a new member registration (to my admin email)… and the notice also appears in the admin panel saying there’s a user awaiting moderation.

    And that’s where Im at.

    Come to think of it, and after having read through this post several times now- It seems that the plugin’s actually working… with the exception of those errors that are flagging up in the admin panel (when editing the emails that will be sent out), and at the top of the front end page. Hopefully one of you guys can tell me how to get rid of those errors… or at least the ones on the front end. :-)

    This truly does sound like a fantastic plugin, but with non-existent support at the forum link in the README.txt file, I think it can only carry on living if one of you geniuses are willing to fix the bugs.

    Unless anyone knows of another plugin that will allow new member moderation? (I have searched, but couldnt find anything).

    Boone Gorges
    Keymaster

    As for your other question, here are a few places to start:

    1) Make a Gender field and a Enter the Competition field in Dashboard > BuddyPress > Profile Fields. Make sure they’re required on registration.

    2) If by “top nav menu” you mean the thing that floats across the top of the screen, you can add to it by creating a button inside of a php function, then using add_action to attach the function to the bp_adminbar_menus hook. See buddypress/bp-core/bp-core-adminbar.php to see how it works in the core code.

    3) Use a plugin like JJJ’s https://wordpress.org/extend/plugins/bp-member-filter/ to create the filters that will populate the pages that the “Men” and “Women” dropdowns will point to.

Viewing 25 results - 3,101 through 3,125 (of 3,593 total)
Skip to toolbar