Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'profile fields'

Viewing 25 results - 1,276 through 1,300 (of 3,608 total)
  • Author
    Search Results
  • #182194
    Mathieu Viet
    Moderator

    Hi,

    Make sure to leave the base group profile fields available for all users

    Then explore in this direction :

    /* Profile display */
    function excluding_group_id_depending_on_user_role( $args = array() ) {
    	if ( user_can( bp_dispayed_user_id(), 'capability_to_check' ) {
    		$args['exclude_groups'] = "2,3,4"; //Comma-separated list of profile field group IDs to exclude
    	}
    	return $args;
    }
    add_filter( 'has_profile', 'excluding_group_id_depending_on_user_role', 10, 1 );

    /* profile editing */
    It will be a bit more complex as you’ll need to filter ‘xprofile_filter_profile_group_tabs’ and use a pattern to exclude the tabs you don’t want the role to edit.

    Finally to restrict group creation, i’ve shared a code on the BuddyPress fr community :
    http://bp-fr.net/agora/sujet/restreindre-la-creation-des-groupes-a-des-roles-wp/

    #182114
    investacube
    Participant

    Thanks for the quick reply @naijaping, I should have said that at the moment members changing their avatars is the only profile update that shows in my activity stream. I would like to add to that the changes made to personal profile fields. I appreciate the link to bp-tricks, I haven’t yet ventured into coding my own stuff but do you think the avatar change code is something that could be tweaked to include profile fields changes?

    klogan2
    Participant

    SO it seems the ‘Profile Details’ portion of the registration form, in spite of the fact that the people that wrote the BP app allow for ‘required’ fields in the ‘Profile Details’ portion of the form, neglected or forgot to include validating the ‘Profile Details’ portion of the form (OR chose NOT to),,,, anyone know how to do this???,,, as efficiently as it’s being done for say the user/email/password fields???
    I’ve been reading up on validating forms,,and it actually seems like something I could do, but not without rewriting the BP files,,which I would really like to avoid (BP updates would overwrite the changes). I would think it might be possible to do via the theme function files,,,but beyond adding a function here, or a filter there, my knowledge/experience wouldn’t be sufficient I think to accomplish this task,,,
    So,,any ideas/methods how to deal with this?? Answers would be greatly appreciated.
    Cheers, Kevin Logan

    klogan2
    Participant

    hmmm, no,, maybe I didn’t ask a silly question, I don’t think there ARE error fields for the extended profile registration fields,, along the lines of bp_signup_password_errors and then do_action( 'bp_signup_password_errors' ); in the appropriate places,,, which in this case would seem to be in the div class=editfield.
    Don’t know yet how to solve this,,, but thinking about it

    #182034

    In reply to: 2.1 top features

    SK
    Participant
    klogan2
    Participant

    The page does refresh (when a required field is left empty), drops one or 2 of the values (like month & year in a birthdate field),,, but doesn’t show the error messages for any blank fields in the Profile portion of the form.
    Thanks for your suggestion,,, I’d say that’s probably way over my head,,,I might be able to do it ‘eventually’,, but I hope an easier solution comes up 🙂
    Missing Error Messages in registration form

    #181946
    jerryskate
    Participant

    Yeah it might be correct, but it doesn’t work. I have tried pretty much anything regarding the body class, but the page doesn’t output anything i can use. It works at the main profile page, where my last slug is unique to the username, but as soon as you click on any tabs at the profile page, its lost, since the slug change to a more universal one. Here´s some of the things i tried, to no luck. https://wordpress.org/support/topic/give-pages-truly-unique-id´s-classes-possible?replies=23

    This is the page output:

      [page] => 0
        [pagename] => profile
        [error] =>
        [m] =>
        [p] => 0
        [post_parent] =>
        [subpost] =>
        [subpost_id] =>
        [attachment] =>
        [attachment_id] => 0
        [name] => profile
        [static] =>
        [page_id] => 0
        [second] =>
        [minute] =>
        [hour] =>
        [day] => 0
        [monthnum] => 0
        [year] => 0
        [w] => 0
        [category_name] =>
        [tag] =>
        [cat] =>
        [tag_id] =>
        [author] =>
        [author_name] =>
        [feed] =>
        [tb] =>
        [paged] => 0
        [comments_popup] =>
        [meta_key] =>
        [meta_value] =>
        [preview] =>
        [s] =>
        [sentence] =>
        [fields] =>
        [menu_order] =>
        [category__in] => Array
            

    As you can see the page doesn’t output a class unique to the profile, so doesn’t seems to work to filter the bodyclass.

    Must be another way of doing this?

    elaborate
    Participant

    I guess I might as well add the details now.

    My work so far has involved editing the bbPress and BuddyPress template files. I add the forms from the bbPress Edit page’s template file and paste them in the BuddyPress Settings page’s template file, which I then use.

    My problem is that the data for the users profiles does not appear in the relevant bbPress Edit fields now that the forms reside on the BuddyPress settings page with a different URL.

    I looked up how HTML forms work with PHP and found out that the action attribute in a <form> tag is the URL for the destination of the input, so you might think that changing the URL of the bbPress forms to the BuddyPress Settings page would solve the problem, but it doesn’t.

    Doesn’t the user data need to be sent to and retrieved from the database somehow?

    Thanks.

    #181622

    In reply to: Proximity Search

    csimpson
    Participant

    hi there, ive found something that appears to do the job tonight as i require this to.

    You will need to use “xprofile-fields” plugin and then use the wp plugin at https://geomywp.com/ used in conjunctions with their paid add-on found here: https://geomywp.com/add-ons/xprofile-fields/

    regards Craig

    #181487
    modemlooper
    Moderator

    Most plugins that add user fields are for the WordPress profile. The new Extended profile in the admin is for BuddyPress specific user information.

    #181336
    jerryskate
    Participant

    Well, this didn’t work.. It only works for my main profile page where my slug/url is unique to the profilname. If i click other fields in the profile page, notifications, activity etcetera the url changes, and so does my css changes.

    Any other ideas?

    Henry Wright
    Moderator

    The best approach is to list all of the places a member can enter text then try to lock each one down.

    Off the top of my head I can think of:

    The WP admin area – creating posts and pages etc

    Comments (if you have comments enabled)

    The BP profile area (xProfile fields)

    The activity stream (commenting, replies, new updates etc)

    Private messaging?

    #181170
    serks
    Participant

    Hi have a very similar issue and I think it may be related to the same cause.

    I have set up a xprofile group where I have a bunch of different radio fields like so…

    About You Widget
    Show | Hide

    Display Avatar On Profile
    Show | Hide

    Subscribed Member Badge
    Show | Hide

    etc.

    I have put code all around my website to show or hide things according to a users settings and it all works as it should BUT, the only problem is that the settings don’t take effect until a user goes to edit the particular profile group and clicks the ‘Save Changes’ button.

    Even though the defaults are set as they should be initially, they do not actually work until the user saves them.

    Any help on this issue would be much appreciated.

    Thanks

    #180981
    shanebp
    Moderator

    We provide a premium plugin for reporting:

    BuddyReports

    But it does not show data re profile fields.

    Re ‘checked boxes’ – you would want a total of the number of members who have checked box ‘x’ or a list of all members who have done so ?

    #180922
    shanebp
    Moderator

    If ‘offer service’ and ‘search service’ are extended profile fields, you can adapt this example:

    BP_User_Query

    #180865

    Thanks for the feature request. At this time BuddyPress only provides visibility settings for individual profile fields. We’ve been putting off building a robust member to member permissions component until after we have attachments. Right now, everything in BuddyPress is loosely considered public.

    Remember that BuddyPress is still powered by WordPress, and WordPress’s roles and capabilities system isn’t really powerful enough or scalable enough to handle permissions for millions to millions of users.

    That said, there have been plugins that attempted to fill this void, but none of them gained a whole ton of traction unfortunately. We’ll get there, but it’s a bit of a long road.

    Jonbie
    Participant

    Hi Hugo,

    Thanks for the quick reply.

    I have a child theme already set up and i have put the following code into member-header.php but i am unsure of exactly where to put it and if the code is 100% accurate?

    <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

    #180781
    Lerroy
    Participant

    Ok I was able to fix this issue.

    I added this code to my members-header.php

    <?php $Name = bp_get_profile_field_data( 'field=Name' ) ;
    echo '<h2 class="Name-fields_main">' .$Name. '</h2>';
    ?>

    added the code on line 22 just under this

    <div id="item-header-content">

    #180778
    Lerroy
    Participant

    Ok
    After allot more research I found a solution. looks like I was putting your code in the wrong spot sure it would have worked as well @Barney

    I used this code

    <?php
       
      $state = bp_get_profile_field_data( 'field=State' ) ;
    echo '<p class="profile-fields">State: ' .$state. '</p>';
    ?>

    This displays my custom field state that i added via users > profile feeds in backend of wordpress

    I put this code under

    <span class="activity"><?php bp_last_activity( bp_displayed_user_id() ); ?></span>

    this is all in the members_header.php in the bp_legacy section

    #180758
    Lerroy
    Participant

    @Barney

    Thanks for pointing me to that.

    I’m still struggling though PHP aint my thing 🙁

    So the primary field “Name” and my other fields are called “State: and “Organization” and “Website” these are the field names I insert ?

    Heres where i put it..But doesnt show full member-header

    ` </div><!– #item-buttons –>

    <?php
    /***
    * If you’d like to show specific profile fields here use:
    * bp_member_profile_data( ‘field=About Me’ ); — Pass the name of the field
    */
    do_action( ‘bp_profile_header_meta’ ); // Here is one way you could add xprofile fields name as well as the value to the members directory!
    // Just remember to replace “Field-Name” with the names of your fields in the 5 variables in my code.
    // Also remember the field name is case sensitive. If you notice the pattern of 5 in my code you can
    // easily see how to add more fields if you need them. You can also use the div class bph_xprofile_fields
    // to adjust the CSS in your stylesheet. Place this code in bp-custom.php:
    add_action(‘bp_directory_members_item’, ‘bphelp_dpioml’);
    function bphelp_dpioml(){
    $bphelp_my_profile_field_1=’Name’;
    $bphelp_my_profile_field_2=’State’;
    $bphelp_my_profile_field_3=’Organisation’;
    $bphelp_my_profile_field_4=’Website’;
    $bphelp_my_profile_field_5=’About-you’;
    if( is_user_logged_in() && bp_is_members_component() ) { ?>
    <div class=”bph_xprofile_fields” style=” margin-left: 25%;”>
    <?php echo $bphelp_my_profile_field_1 ?>: <?php echo bp_member_profile_data( ‘field=’.$bphelp_my_profile_field_1 ); ?><br />
    <?php echo $bphelp_my_profile_field_2 ?>: <?php echo bp_member_profile_data( ‘field=’.$bphelp_my_profile_field_2 ); ?><br />
    <?php echo $bphelp_my_profile_field_3 ?>: <?php echo bp_member_profile_data( ‘field=’.$bphelp_my_profile_field_3 ); ?><br />
    <?php echo $bphelp_my_profile_field_4 ?>: <?php echo bp_member_profile_data( ‘field=’.$bphelp_my_profile_field_4 ); ?><br />
    <?php echo $bphelp_my_profile_field_5 ?>: <?php echo bp_member_profile_data( ‘field=’.$bphelp_my_profile_field_5 ); ?><br />
    </div><?php
    }
    }

    ?>’

    #180735
    SimpleOne
    Participant

    @espellcaste, I had already read through that WP doc you referenced. That’s actually where I learned what lines of code to add to my wp-config.php file that I mentioned above.

    And yes, it is redirecting to the BP Registration page. That’s expected behavior since I have my BP settings that way. (I have some custom BP profile fields that I want users complete during registration.)

    I have posted my question here (as opposed to WP support) because it seems to me the issue may have something to do with how I have BP setup to interact with WP. And so I would think that someone else perhaps has encountered this same issue with BP and the Registration page.

    Anyone?

    #180697
    Renato Alves
    Moderator

    @cdb3212 As far as I understood your problem, there are two articles that would save your life if you had a chance of looking in the Codex. These are:

    https://codex.buddypress.org/getting-started/guides/displaying-extended-profile-fields-on-member-profiles/

    bp_profile_field_data()

    Take a look at those and try it out. =)

    #180695
    Renato Alves
    Moderator

    Hi @theatereleven,

    I’d say that what you aim for is perfectly possible with BuddyPress. You could the following, just suggestions:

    • Your users could register themselves;
    • Just active the Extended Profile component;
    • Use Extended Profiles Fields so that your users can add information when signing up or later;
    • And you could customize the appearance customizing the template the way you want.

    Maybe there is a better solution, but with BuddyPress you would get already built-in, profiles, profile fields, register process/page, user roles and etc.

    #180653

    In reply to: field visibility

    @shanebp Had support from the developer of xprofile. He thinks has something to do with buddypress. I don’t know. What I do know is that if I have the following code in the members-loop file:
    <?php $hidden_fields = bp_xprofile_get_hidden_fields_for_user(bp_get_member_user_id()) ; ?>
    <?php if (xprofile_get_field_data(‘field_name’) && !in_array(xprofile_get_field_id_from_name(‘field_name’), $hidden_fields)) : ?>
    <?php echo xprofile_get_field_data (‘field_name’); ?>
    <?php endif; ?>

    <?php bp_member_profile_data( ‘field=Adres’ ); ?>

    The first code with $hidden_fields and xprofile doesn’t return anything.
    The second code does always return data, no matter how visibility is set.

    Any ideas?

    #180432

    In reply to: BP search box

    loufernando
    Participant

    Thanks Renato, that makes sense. Hopefully someone might know how to add the text in the profile fields searchable so they appear in the search results.

Viewing 25 results - 1,276 through 1,300 (of 3,608 total)
Skip to toolbar