Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'profile fields'

Viewing 25 results - 951 through 975 (of 3,608 total)
  • Author
    Search Results
  • Quinn Goldwin
    Participant

    Never mind I used this css coding to add line breaks, still not perfect but it looks so much better than it used to!

    #buddypress table.profile-fields p {
    	margin-top: 10px !important;
    	margin-bottom: 10px !important;
    }
    
    Henry Wright
    Moderator

    Right. So it looks as though it could be something the BuddyPress core team might need to look at. Can you open a Trac ticket explaining how the profile fields are displaying in the wrong order? If you could provide as much info as you can that’d be great.

    You can use the same username and password as you use here in the forums.

    #241481
    whoaloic
    Participant

    Hello,
    actually I mean to merge content of members/single/settings/general.php and members/single/profile/edit.php.
    My idea is to get custom BP profile fields (username) along with the email and password fields in the general settings tab.
    When I copy plugins/buddypress/bp-templates/bp-legacy/buddypress/members/single/ to mytheme/buddypress/members/single/, those files don’t override plugin core files.

    #241425
    Anonymous User
    Inactive

    Hello danbp,

    So far i understand you use bbPress and now you want a members directory, and eventually some additionnal fields on user’s profiles. And most of this should be private or “members only”, right ?
    >> Correct, combined with private bbpress forums on a website with also public content.

    I have set the “members” page I created as private, but it is still displayed when I go on the page as a logged out user. Why is that so?
    Would it work if I would not connect the “members” page with BuddyPress in the settings, set the page to private and pull the dynamic content for the members list by a stortcode?

    I can read into the codex of course, but do I need to learn to code to use BuddyPress?

    Nicole

    #241424
    danbp
    Participant

    Hi @nmschaller,

    bbPress is a separate plugin and BuddyPress doesn’t manage bbPress. For questions about forum settings, you can use the bbPress support.

    When you use BP groups component, you can add a forum to each of them. In this case only, you have to install bbPress. Of course you can also use bbPress as standalone on a BP install, or use bbPress with WordPress, without BP.

    BP doesn’t use “pages” but templates, and the only pages created during installation are in for internal purpose. The “member” page is used to show the member directory, but also profiles or members activities. This dynamic content is displayed on different templates, depending the context, and using WP’s page system to fire all that via a same page slug (aka internal path).

    your-site/members/some/thing/ where /some/thing/ is using his own template part displayed on “members page”.

    So far i understand you use bbPress and now you want a members directory, and eventually some additionnal fields on user’s profiles. And most of this should be private or “members only”, right ?

    The main problem is that you want some custom behave that need some knowledge (you seem to have), but you cannot edit functions.php Unfortunately, this is the place where to add customisation. And what to tell about bp-custom, which is another crucial cusmisation file.

    You want to drive and have no steering wheel ! Annoying… 😉

    The question is Do you need BuddyPress or can you use another solution ? 🙂

    Depends your project, really. Members directory or extended profiles can be done with separate plugins.

    Read here:
    http://chrislema.com/best-wordpress-membership-plugin-2014/

    Or digg into the Codex if you decide to use BuddyPress.

    #241391
    shanebp
    Moderator

    There is a filter hook for displaying profile fields – so you don’t need to hack core files.

    apply_filters( 'bp_get_the_profile_field_value', $field->data->value, $field->type, $field->id );

    Use str_replace to insert your target blank string.

    function swiss_target_blank( $field_value, $field_type, $field_id ){
    	
    	if( $field_id == 123 ) { // get the field_id from edit field url in wp-admin
    
    		$field_value = str_replace('rel="nofollow"', 'rel="nofollow" target="_blank"', $field_value);
    	}
    
    	return $field_value;
    }
    add_filter('bp_get_the_profile_field_value', 'swiss_target_blank', 11, 3);
    danbp
    Participant

    How to create MT is explained above, and you’re lucky, as a brand new plugin was published a few days back by @offereins: BP XProfile Field For Member Types

    Proof of concept for the implementation of member-type specific profile fields in BuddyPress.

    https://github.com/lmoffereins/bp-xprofile-field-for-member-types

    Successfully tested with my custom code(in bp-custom.php), BP 2.3.2.1 and WP 4.2.2

    #241319
    danbp
    Participant

    See if this can help you:
    https://buddypress.org/support/topic/men-woman-couple/

    Also some topics about multi search criteria, like this one
    https://buddypress.org/support/topic/multiple-search_terms-displays-nothing/

    Note also that xprofile fields values are clickable by default. This let users get a list of members who entered same value.

    Field name > Gender, when male is clicked you get all males list.

    For more detailed result, you have to buid your own solution or to use a dedicated plugin. See
    https://wordpress.org/plugins/buddypress-global-search/

    #241298
    danbp
    Participant
    Aethermage
    Participant

    Thank you for your reply @danbp.

    I actually created the profile field myself in Dashboard > Users > Profile Fields to emulate a captcha plugin. For some odd reason it appears under Account Details instead of under Profile Details on the Register page and is missing from the backend so I am unable to edit/delete it.

    #241044
    shanebp
    Moderator

    If the role is set to vendor and xprofile fields are not involved, then there is a WP hook for that.

    Assuming the group_id is 8, try:

    function jeffery_join_vendor_group( $user_id, $role, $old_roles ) {
    	if( $role == 'vendor' ) {
    		groups_accept_invite( $user_id, 8 );
    	}
    }
    add_action( 'set_user_role', 'jeffery_join_vendor_group', 11, 3 );
    #241005
    danbp
    Participant

    When you use WordPress alone, you can use many plugins for registering.

    If you use BuddyPress, you also use his fonctionnalities.
    One of them, is Members, which comes also with extra components, like extended profile.

    When you use extended profile, it is like using a register plugin for WP, with his own extra fields you can create/add to the original WP registering process. After that, each user can handle/view these fields on his profile.

    Now you have to choose:
    – WP alone, with his poor profile fields
    – WP + BP, with rich profile fields
    – WP + BP, without xprofile component (and users go back to the original profile fields aera).
    – or ask on ninja plugin support for improvement guidance to apply with BuddyPress.

    #240969
    peter-hamilton
    Participant

    One of the few things I not tried much is the add profile fields option, this is where I guess that can be achieved

    Small example on my sites profile

    #240825
    ct25
    Participant

    Today I found there was a member-loop.php added to my theme files. Could this be part of the problem? Should I add the member template file to the theme as well?

    <?php
    
    /**
     * BuddyPress - Members Loop
     *
     * Querystring is set via AJAX in _inc/ajax.php - bp_dtheme_object_filter()
     *
     * @package BuddyPress
     * @subpackage bp-default
     */
    
    ?>
    
    <?php do_action( 'bp_before_members_loop' ); ?>
    
    <?php if ( bp_has_members( bp_ajax_querystring( 'members' ) ) ) : ?>
    
    	<div id="pag-top" class="pagination">
    
    		<div class="pag-count" id="member-dir-count-top">
    
    			<?php bp_members_pagination_count(); ?>
    
    		</div>
    
    		<div class="pagination-links" id="member-dir-pag-top">
    
    			<?php bp_members_pagination_links(); ?>
    
    		</div>
    
    	</div>
    
    	<?php do_action( 'bp_before_directory_members_list' ); ?>
    
    	<ul id="members-list" class="item-list" role="main">
    
    	<?php while ( bp_members() ) : bp_the_member(); ?>
    
    		<li>
    			<div class="item-avatar">
    				<a href="<?php bp_member_permalink(); ?>"><?php bp_member_avatar(); ?></a>
    			</div>
    
    			<div class="item">
    				<div class="item-title">
    					<a href="<?php bp_member_permalink(); ?>"><?php bp_member_name(); ?></a>
    
    					<?php if ( bp_get_member_latest_update() ) : ?>
    
    						<span class="update"> <?php bp_member_latest_update(); ?></span>
    
    					<?php endif; ?>
    
    				</div>
    
    				<div class="item-meta"><span class="activity"><?php bp_member_last_active(); ?></span></div>
    
    				<?php do_action( 'bp_directory_members_item' ); ?>
    
    				<?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' );
    				  */
    				?>
    			</div>
    
    			<div class="action">
    
    				<?php do_action( 'bp_directory_members_actions' ); ?>
    
    			</div>
    
    			<div class="clear"></div>
    		</li>
    
    	<?php endwhile; ?>
    
    	</ul>
    
    	<?php do_action( 'bp_after_directory_members_list' ); ?>
    
    	<?php bp_member_hidden_fields(); ?>
    
    	<div id="pag-bottom" class="pagination">
    
    		<div class="pag-count" id="member-dir-count-bottom">
    
    			<?php bp_members_pagination_count(); ?>
    
    		</div>
    
    		<div class="pagination-links" id="member-dir-pag-bottom">
    
    			<?php bp_members_pagination_links(); ?>
    
    		</div>
    
    	</div>
    
    <?php else: ?>
    
    	<div id="message" class="info">
    		<p><?php _e( "Sorry, no members were found.", 'buddypress' ); ?></p>
    	</div>
    
    <?php endif; ?>
    
    <?php do_action( 'bp_after_members_loop' ); ?>
    
    #240478
    patrix87
    Participant

    Same problem here,

    I’ve even tried to modify xprofile_filter_kses directly to add img tag without any success.

    Apparently the fields are being filtered more than once.

    here’s my modified code

    function xprofile_filter_kses( $content, $data_obj = null ) {
    	global $allowedtags;
    
    	$xprofile_allowedtags             = $allowedtags;
        $xprofile_allowedtags['a']['img']['rel'] = array();
    
    	$xprofile_allowedtags = apply_filters( 'xprofile_allowed_tags', $xprofile_allowedtags, $data_obj );
    	return wp_kses( $content, $xprofile_allowedtags );
    }
    
    #240238
    CodeMonkeyBanana
    Participant

    @shanebp Thanks for the reply.

    […]in any relational table, if an item is assigned to a group ID and that group ID no longer exists in the table that holds group IDs, then that data will not be displayed, ie. orphaned.

    I deleted through the admin panel so I am not sure what was deleted, that was what I meant by asking if is was standard behaviour. Possibly what I should have said is; when a user deletes a group by using the ‘bp-profile-setup’ page to click on the ‘delete group’ button, is buddypresses default behaviour to just drop the group and leave the profile data in the table or does it also iteratively remove the profile fields?

    I can see the reason why you would want to leave the data in the table (and also reasons why you wouldn’t). I had a quick look at the code but I am not familiar enough with it yet to pinpoint the exact code block.

    If fields are not deleted then I guess any fields directly referenced would still be visiable on the site. That may be misleading to user as they may assume deleting a group would also remove fields. However you wouldn’t want a group to be deleted by accident and then a large amount of data be lost. I would guess a system of deleting the group and then updating each profile field to explicitly notify calling functions that their parent has been deleted would be appropriate in the circumstance.

    I have used a relational database before but I am unfamiliar with the logic employed by buddypress to interact with it.

    The behaviour I was was getting was weird. When I deleted a group and created it again no fields were showing. Then when I added a field, it had a value immediately after creating so something weird was going on so I thought I would ask to see if you knew if the profile data gets deleted when a user clicks delete group in admin panel.

    I am starting again now so will pay closer attention to all data as it goes into fresh tables but sometimes it is harder to see to absence of data compared to the addition of new data.

    Why? BP will always create a Base group.

    I am running a multisite where individual user blogs can create their own fields (https://codex.buddypress.org/themes/guides/segregated-x-profile-fields-for-multisite/).

    As the article says:

    This code will not create dummy content, so for every new site you will need to create a Profile Fields group and add profile fields to it manually.

    When I create new site there are no field groups made at all which I assumed is what it was talking about. Also I wanted to have a default set of groups but allow subsite to edit them. If they want to get default groups back they can just delete all their groups and default will be restored. I could add a separate button for that but I just figured I’d do it like this, no particular reason, I am still in early stages of project.

    I think there were other errors at play so starting from scratch with a little more understanding will hopefully enlighten me. I will be duplicating tables this time instead of using meta table.

    #240141
    shanebp
    Moderator

    This is a basic mysql table structure issue.

    The id field is set to auto increment.
    So it you really want the id to be 1, you need to flush the bp_xprofile_groups table.
    But that may orphan any data you have in bp_xprofile_fields or cause mismatches with data in the
    bp_xprofile_data table.

    Perhaps the id field should not be an argument in xprofile_insert_field_group.

    Does it really matter what the id is?

    #240140
    Henry Wright
    Moderator

    Yeah sounds like it could be your database preserving referential integrity. i.e. Can’t delete a profile group unless all fields belonging to that group have been deleted first.

    Check what’s going on by looking at your database. This may help:

    BuddyPress Database Diagram

    #240114

    In reply to: Per-group Identity?

    Tony G
    Participant

    Well, group meta allows meta data to be applied to groups. I’m thinking along the lines of data in the usermeta table which is only consumed by specific groups. This might be expressed as a name/value pair in the profile. So with reference to my original example, a GroupName profile value would include:
    school:Robert
    home:Bobby
    coolGame:Zarcon

    The BuddyPress Profile Shortcodes plugin allows for custom fields and related shortcodes to be used. This is much closer to my needs but still not quite there. I can’t create a profile field for every possible group. Ideally there would be a pulldown of groups to which the user belongs, where they can enter the name they wish the use for that group, and the group/name pairs would be displayed in a grid.

    Now I’m thinking one of the better user meta plugins could handle that. But I would also need to customize it so that there can only be one WP user with a specific value for a specific group. This is a unique key per group, as some reference to @Bobby can’t apply to more than one person, but the @Bobby in one group can be different from @Bobby in another group.

    On the client side, I would then need to modify bbPress to get the user name that’s specifically for the current group, rather than using wp_get_current_user()->display_name or whatever it has there. For example:
    get_user_meta($user_id,’groupName_’.$group_id,true)
    or better
    get_user_meta($user_id,’groupNames’,false)[$group_id]

    Actually I’d rather abstract all requests for a user name to a function which can then be replaced with custom code just once. I don’t suppose anyone has already done that, or it’s been proposed as a BP/BBP enhancement?

    I’m a noob with coding into WP, haven’t touched BP/bbP, and know little about the APIs, so please bear with me on the syntax and other specifics and focus on the concepts. Thanks.

    The more I try to flesh it out above the more it seems possible for me to do this myself. But it would be really helpful if someone has already done it. Or if someone with knowledge in this area can see a more direct line from an exiting plugin to the solution I’m describing.

    Thanks for your time!!

    #240029
    shaquana_folks
    Participant

    My apologies @danbp I had a plugin called “BuddyPress xProfile Custom Fields Type” set up, that’s where the button came from. I just deactivated the plugin. But even when I still try to fill out the registration form, there’s no error that shows up this time, however, it takes me right back to that same registration page and it still did not create that new user for me. It would still just show up on the screen like this:

    New registration screenshot

    Any suggestions why this is still happening? Also, is there a good plugin that anyone can recommend for me to use so that when users create their profiles, they’ll be able to upload a profile picture?

    #239985
    CodeMonkeyBanana
    Participant

    I’ve been staring at the code for a while and it’s starting to make sense.

    I’m not great with databases but looking at the function I gather it changes a few fields into primary keys that point to the data table so fields can be individual.

    It runs the table modification code on the dbdelta_create_queries hook.

    The wordpress codex seems to say that this action will happen anytime a database or a table is created.

    Am I right in saying that this only ever has to be run once? Can I just run it once on admin init then remove it and add the modify_bp_global_xprofiles_tablenames at runtime or have I misunderstood it?

    #239800
    shanebp
    Moderator

    I’m calling it from the buddypress-xprofile-custom-fields-type plugin, do you think could be some filter that intercept querystring and reset it ?

    I doubt it.
    Where in the plugin are you calling it?
    In a function?
    And what is that function hooked to?
    Is that hook being called on the page where you manually call the $_GET? Probably not.

    #239799
    city4run
    Participant

    Hello Shane,
    I called manually the URL in the browser with the ?var1=TEST to be sure that it’s called properly but nothing change.

    I’m calling it from the buddypress-xprofile-custom-fields-type plugin, do you think could be some filter that intercept querystring and reset it ?

    danbp
    Participant

    Please search before asking. Search: Remove Profile Links brings up:

    https://buddypress.org/support/topic/on-profile-base-answers-to-fields-works-as-links/

    tstrickland415
    Participant

    Ok now everything works as you mentioned, but there’s just one caveat. The xprofile gets updated fine, but it’s not updating the actual Members Type field in the Extended Profile section of the Users panel in the backend.

    To clarify, when we make the xprofile field it’s a completely separate field than the Members Type field that Buddypress introduced recently. So in the Users->Extended Profile section there’s two fields for Member Types, the one we created and the one Buddypress introduced. Your code is only affecting the one we created and not the real Buddypress Member Type field. Is there a way to have the BP Member Type field get updated with the corresponding member type from the xprofile field?

Viewing 25 results - 951 through 975 (of 3,608 total)
Skip to toolbar