Search Results for 'profile fields'
-
AuthorSearch Results
-
March 18, 2015 at 6:40 pm #236219
In reply to: Get all options from custom profile field
ckchaudhary
Participantfunction wdw_bp_get_field_options( $field_id ){ global $bp, $wpdb; return $wpdb->get_col( $wpdb->prepare( "SELECT name FROM {$bp->profile->table_name_fields} WHERE parent_id=%d AND type='option'", $field_id ) ); }You can call the above function passing id of the field( fieldabc in your example ). This will return all options of the field in an array.
March 16, 2015 at 5:33 am #236094In reply to: Help setting up BuddyPress on WordPress site
@mercime
ParticipantDo you recommend I create text/content and install a form plug-in for my ‘register’ page associated with the BPress first before working on adding Member Profile Fields?
@dleit please do not install any form plugin for your “Register” page. Leave it blank as BuddyPress will dynamically add the necessary forms. What you need to do is set up the profile fields. Remember that whatever field you add in the first group of the profile field will appear on the right side of the Reigstration form.It just doesn’t seem like it will solve the “user registration is currently not allowed” issue.
After you add the member profile fields/group(s) you want for your community, I suggest going to the admin menu Settings > General and Allow Registrations. BP Codex is your friend https://codex.buddypress.org/getting-started/register-and-activation-pages/
March 15, 2015 at 3:22 am #236032In reply to: Help setting up BuddyPress on WordPress site
RecDC
ParticipantDo you recommend I create text/content and install a form plug-in for my ‘register’ page associated with the BPress first before working on adding Member Profile Fields? It just doesn’t seem like it will solve the “user registration is currently not allowed” issue. Thank you for the link there on adding Member Profile Fields (I feel confident in doing that). It just dawned on me that my site should look like this in some ways because the BPress is in use.
March 15, 2015 at 2:40 am #236030In reply to: Help setting up BuddyPress on WordPress site
@mercime
ParticipantI created a page for each component in this plug-in and I don’t know what to do next.
@dleit It depends. You could start adding Member Profile Fields and/or Create Groups and/or install Group and/or Sitewide Forums if you need forums.btw, spammers have been removed 🙂
March 13, 2015 at 10:23 am #235940In reply to: group for logged in user
howsepa
ParticipantAnother option….
If this wont work – i could also use custom fields in the extended profile feature of buddypress and set up a field to contain this ‘category’ information.
Either would work.. but need to store a category for each user and capture this as they log in.
March 11, 2015 at 3:47 am #235826In reply to: Registration text not applying – how do you edit?
5high
ParticipantOK, I’m a newbie with BP but you have to:
1. edit/set up your registration page form fields that you want in Users > profile Fields.
2. you can edit the actual text found in the Registration page in registration.php file. Found here on your server: plugins/buddypress/bp-themes/bp-default/registration/register.php
3. you can edit the actual text found in the Activate page in activate.php file. Found here on your server: plugins/buddypress/bp-themes/bp-default/registration/activate.phpIf you read the getting started docs they help a lot, and then search this forum and on the i/net you’ll find heaps more info.
Good luck!
March 11, 2015 at 1:41 am #235825rosyteddy
Participanthttp://seventhqueen.com/support/forums/forum/kleo/kleo-general-questions
Hi @sjjenkins
This should not be very difficult. Some small change in the template file but since they have no downloadable version its difficult to say.
This may contain some clue –Showing some profile fields in member’s profile header not working after update
Just curious, how does the Whats New box looks like when you use
buddypress-activity-privacy, buddypress-activity-plus and any Media plugin like rtmedia ?
Whats your site (if its not private) url ?Thanks.
March 9, 2015 at 2:00 am #235701In reply to: Settings -> Profile Visibility does not display
Xander206
ParticipantI think I got it working although I didn’t quite get the result I expected based on the name “profile visibility”. I expected to see settings like “show my profile to group everyone/members/friends/logged in users”, “show me in the directory”, etc.
Instead the page that loaded shows the various Profile Fields and allows the use to toggle the visibility of each field. This seems very similar to the controls available when the user when editing their profile (where they can set these same visibility settings).
This file: …themes/ibuddy/buddypress/members/single/settings.php
was missing this
case 'profile' : bp_get_template_part( 'members/single/settings/profile' ); break;March 6, 2015 at 6:28 pm #235559In reply to: [Resolved] Spreadsheet Of All User Information
rosyteddy
ParticipantThese may help
wordpress.org/plugins/export-user-data/
wordpress.org/plugins/wp-users-exporter/
buddypress dot org/support/topic/exporting-xprofile-fields-to-csv-etc/[ My previous reply here had many more links, and it just vanished on hitting submit without any alert message, probably was caught as spam]
Thanks
March 4, 2015 at 10:58 pm #235473In reply to: If a number have same number get_avatar
tipsy
Participant@danbp Sorry If I’m blurry, been sitting on and of with this since yesterday 🙂
1. I have 90 users/subscribers.
2. All users are forced to write a number when they registerer. This I force them to do with BuddyPress Profile Fields. This field have the id 2, xprofile_get_field_data(2)
2. I have a plugin “WP Excel CMS” were I render out a excel-document with information on a page. Here I also have numbers. And the value of this cells are $entry[1]
3. Now when I have xprofile_get_field_data(2) and $entry[1] I want to echo get_avatar() of the $user_id in the database who have this number match.
March 4, 2015 at 7:05 pm #235462In reply to: If a number have same number get_avatar
tipsy
Participant@henrywright So I’m trying to get this right, this starting to get more and more fun, even if it doesnt work 🙂
I say
if ($entry[1]is the same as==Profile fields 2 (that the user have been forced to write in that fieldxprofile_get_field_data(2));render avatar from the $user_id that matchecho get_avatar($field);Is this right thinking? But who do I get the $user_id in?
This is my none working code for now. (This one is still spits out the default-avatar but doesn’t grab the users avatar)
<?php if ($entry[1] == xprofile_get_field_data(2)); { echo get_avatar($field); } ?>February 27, 2015 at 9:40 am #235223AfromanJ
ParticipantBasically Ive been asked to fix this field problem on someone elses website, Ive just been given access to FTP so can now make changes to the server files.
They are using a theme called Huddle and have BuddyPress install on the latest version:
http://themeforest.net/item/huddle-wordpress-buddypress-community-theme/835549The theme folder has a members folder in for BuddyPress, which i assumed was the standard for BuddyPress. I have overridden the templates you suggested in /themes/huddle/members/single and the issue is still present.
I switched to a default WordPress theme to test compatibility and the fields are working like normal. So the issues is with the Huddle theme, now that its using the correct profile-loop and edit templates im not sure what the problem can be?
February 26, 2015 at 12:47 pm #235171Hugo Ashmore
ParticipantThose two fields do work fine, I suspect that you are working with an older version of the view & edit templates? The manner in which xprofile fields are looped to be displayed changed so you will need to grab latest versions of these templates from the bp-legacy directory in the core plugin.
February 21, 2015 at 3:55 pm #234912In reply to: Adding a Title to a User Name
Outdoorsmen
ParticipantThere was an interesting article on wpmudev.org that shows how to add the profile fields and a few other tricks. The hardest part was determining the exact location for the data.
Thanks for your help.
February 21, 2015 at 2:28 pm #234906In reply to: How to edit page of user profile edit page
danbp
ParticipantBumping after 20mn is a bit abused, no ?
If you use BP, you can edit, add or remove custom profile fields if you activate the extended profile component.
To add an external plugin to the user profile edit, try to add it to the profile template.
Or modify the plugin so he use BP specific templates.
and much more to read on codex and forum.February 20, 2015 at 1:52 am #234830In reply to: Adding new 'Order By' on members loop
shanebp
ModeratorThis works for me. It’s basically just a cleaner version of what eberger3 did.
You’ll have to hack the ‘where’ clauses if you want to include search terms.function add_sortby_price() { ?> <option value="price">Price</option> <?php } add_action( 'bp_members_directory_order_options', 'add_sortby_price' ); function users_sortby_price( $object ) { global $wpdb, $bp; // Only run this if price option is selected if ( ! in_array( $object->query_vars['type'], array( 'price' ) ) ) return; $field_id = $wpdb->get_var( $wpdb->prepare( "SELECT id FROM {$bp->profile->table_name_fields} WHERE name = %s", $object->query_vars['type'] ) ); $object->uid_name = 'user_id'; $object->uid_table = $bp->profile->table_name_data; $object->uid_clauses['select'] = "SELECT u.{$object->uid_name} as id FROM {$object->uid_table} u"; $object->uid_clauses['where'] = " WHERE " . $wpdb->prepare( "u.field_id = %d", $field_id ); $object->uid_clauses['orderby'] = "ORDER BY u.value"; $object->uid_clauses['order'] = "ASC"; } add_action( 'bp_pre_user_query', 'users_sortby_price' );February 19, 2015 at 3:30 pm #234792In reply to: User can't edit profile in frontend
danbp
ParticipantBuddyPress was made to extend WP standart profile fields. Normally you haven’t to use WP’s profile fields (aim, jabber, bio, etc) I you need a bio you recreate one.
The only required fields for profiles at the registering level are 4 by WP (username, email, password & pwd confirm) and the Base (field group) Name field which is added by BuddyPress.
If you use bbpres as standalone forum aside BP, you can syncing with wordpress
February 19, 2015 at 12:14 pm #234772In reply to: User can't edit profile in frontend
Matthias
ParticipantDid not find a solution to work it out with the standard wordpress fields.
The only way to go around this problem, was setting up xprofile fields…February 18, 2015 at 7:18 pm #234700In reply to: User can't edit profile in frontend
Matthias
ParticipantI think @azinfiro had the same problems a few month ago.
Seems it is the normal buddypress behavior, not to show the wordpress fields
https://buddypress.org/support/topic/wp-profile-fields-not-editable-in-bp-profile/This is a bit strange, cause I can change the wordpress fields in bbpress but not in buddypress?!?!
Makes no sense to me!Thanks
MatthiasFebruary 18, 2015 at 5:31 pm #234693In reply to: Adding new 'Order By' on members loop
shanebp
ModeratorYou don’t need to touch any core files to add an Order By.
Example for adding a Contributor option, put in bp-custom.php or theme/functions.php
// add order options to members loop function ch_member_order_options() { ?> <option value="contributing"><?php _e( 'Contributing Members', 'buddypress' ); ?></option> <?php } add_action( 'bp_members_directory_order_options', 'ch_member_order_options' ); // filter ajax members by contributing function ch_filter_ajax_querystring( $querystring = '', $object = '' ) { if( $object != 'members' ) return $querystring; $defaults = array( 'type' => 'active', 'action' => 'active', 'scope' => 'all', 'page' => 1, 'user_id' => 0, 'search_terms' => '', 'exclude' => false, ); $ch_querystring = wp_parse_args( $querystring, $defaults ); if( $ch_querystring['type'] == 'contributing' ) { // to get members by xprofile field, you need some custom sql here // here's an example: //https://codex.buddypress.org/developer/loops-reference/the-members-loop/#code-examples $users = get_users( array( 'fields' => array( 'ID' ), 'role' => 'contributor' ) ); $users_str = ''; foreach ( $users as $user ) { $users_str .= $user->ID . ','; } $users_str = rtrim($users_str, ","); $ch_querystring['include'] = $users_str; $ch_querystring['type'] = 'alphabetical'; return $ch_querystring; } else return $querystring; } add_filter( 'bp_ajax_querystring', 'ch_filter_ajax_querystring', 20, 2 );February 18, 2015 at 1:21 pm #234671In reply to: User can't edit profile in frontend
Matthias
Participanthi @danbp,
I’m using the plugin version of bbpress. And it’s running fine.
I can edit all fields from the backend in the frontend, too under
http://exampample.com/forums/users/USER/editIn buddypress I can access the users profile and I can set the password and the email notifications
BUT
there is no way to change the “public name” and the “website field” oder the “biographical info”
For editing this, the user has to go to the backend!!!Thanks
MatthiasFebruary 16, 2015 at 6:14 pm #234575In reply to: [Resolved] oEmbed in BP Profile
danbp
ParticipantHi @myg0t,
you do it wrong. WP auto embeds youtube videos automagically (and over 40 other online video providers). In a post or topic or mention, simply copy/paste the video URL, and it’s done.
xprofile use a form with different fields. Because these fields are striped for security reason (classic form security), you can’t embed videos like previously described.
But there is a URL field type ?
Yes, this let you enter a video url, but the field will render the URL, not the embed action. It’s a form field and it’s striped.So what ?
We will use a normal text field, and will only enter an alpha numeric value.
How can i do this ?
As example, we gona use this videohttps://www.youtube.com/watch?v=TZPN9g2pmPQAnd to show the video on a profile, we’ll use only the doc ID:
TZPN9g2pmPQBy entering this kind of text in a profile field, it is not striped and will be handled like an ordinary text field and throwed to DB with his filed ID and field value.
To embed the video, we also have to add what WP does on a blog, but not on xprofile page, an iframe to control the video output, so it can be streamed correctly and be read by browsers.
Now we first create a new field and name it Spotlight (or what ever). No matter where, you can use the Base group or any other custom group.
We select the field type and give it a single text area type.
Save.We go on a profile to modify it and enter
TZPN9g2pmPQin regard of Spotlight.
Save.And voilà ! The video is correctly embeded and displayed.
As usual for customisation, we’ll use a snippet which we put into bp-custom.php
function set_video_field( $field_value ) { $bp_this_field_name = bp_get_the_profile_field_name(); // field name (case sensitive) if( $bp_this_field_name == 'Spotlight' ) { $field_value = strip_tags( $field_value ); // building the HTML and h/w of the iframe $field_value = '<iframe width="420" height="315" src="http://www.youtube.com/embed/'.$field_value.'" frameborder="0" allowfullscreen></iframe>'; } return $field_value; } add_filter( 'bp_get_the_profile_field_value','set_video_field');Caution: do not remove the iframe, or video won’t work.
Hope this help.
February 15, 2015 at 10:46 pm #234533danbp
Participanthi @dzagya,
The new BuddyPress comes with SocialMedia fields encoded into the xProfile, and display with the Base profile fields.Is this gonna require a .php hack? – if so anyone got any tips for me?or does anyone know a good plugin to handle this?BuddyPres hasn’t social fields in the Base xprofile field group. There is only one field which is [username] !
Check one of your plugin or your theme setings. Or maybe a custom function…
Give details. Theme & used plugins for example.February 11, 2015 at 12:10 pm #234296In reply to: [Resolved] Bug?
February 11, 2015 at 10:23 am #234282danbp
ParticipantHi @sbraiden,
if you enter love,apple,pie it’s considered as a list, because words separated by commas are list eleents in form (extended profile fields are in a form). If you enter i love apple pie and muffins, but also spaghetti. it’s mostly not linked, except for one of the words before a ponctuation. Or the first word, or the last word in other case. I’ve never tested this precisely.For the URL not showing, do you use the URL field type ? Have you tried with a single line textarea, just to see if this makes a difference.
Also important to know, when you enter an URL on front-end (field type URL on), you have to enter the full URL, http included. If you enter only http://www.sometinhg or example.com, it’s not valid and will be linked like other words to user profile.
-
AuthorSearch Results