Search Results for 'hide xprofile fields'
-
Search Results
-
Hello,
I modified the profile-loop.php file some time ago to hide profile fields that are empty but my code doesn’t work anymore, has any change been done to the code some updates ago ?
Here is what I modified :
<h2 class="screen-heading view-profile-screen"><?php esc_html_e( 'View Profile', 'buddypress' ); ?></h2> <?php bp_nouveau_xprofile_hook( 'before', 'loop_content' ); ?> <?php if ( bp_has_profile('hide_empty_fields=0') ) : ?> <?php while ( bp_profile_groups() ) : bp_the_profile_group(); ?> <?php if ( bp_profile_group_has_fields() ) : ?> <?php bp_nouveau_xprofile_hook( 'before', 'field_content' ); ?> <div class="bp-widget <?php bp_the_profile_group_slug(); ?>"> <h3 class="screen-heading profile-group-title"> <?php bp_the_profile_group_name(); ?> </h3> <table class="profile-fields bp-tables-user"> <?php while ( bp_profile_fields() ) : bp_the_profile_field('hide_empty_fields=0'); ?> <?php if ( bp_field_has_data() ) : ?> <tr<?php bp_field_css_class(); ?>> <td class="label"><?php bp_the_profile_field_name(); ?></td> <td class="data"><?php bp_the_profile_field_value(); ?></td> </tr> <?php elseif ( !bp_field_has_data() ) : ?> <tr<?php bp_field_css_class(); ?>> <td class="label"><?php bp_the_profile_field_name(); ?></td> <td class="data"><?php bp_the_profile_field_value(); ?></td> </tr> <?php endif; ?> <?php bp_nouveau_xprofile_hook( '', 'field_item' ); ?> <?php endwhile; ?> </table> </div> <?php bp_nouveau_xprofile_hook( 'after', 'field_content' ); ?> <?php endif; ?> <?php endwhile; ?> <?php bp_nouveau_xprofile_hook( '', 'field_buttons' ); ?> <?php endif; ?> <?php bp_nouveau_xprofile_hook( 'after', 'loop_content' );Can someone help me to hode those fields again please π
I have a corporate Intranet running on WordPress 4.9.8 and BuddyPress 3.1.0
I have specific xprofile fields that I’d like only editable to people who have the “Edit Users” capability.
I’ve seen snippets of code here or there that almost do what I’m looking for but everything I’ve found is old and out of date.
Could someone help me with this.
Basically I need the PHP equivalent of
If we’re on the edit BuddyPress profile page AND user does not have the “edit users” capability then hide profile fields with X id(s).
I’d also be happy with specifying a role instead of capability as long as I can specify multiple role ids.
Thank you in advance.
Hey everyone,
I have a membership site. It’s running Woocommerce, WP 4.9.6 and Buddypress 3.0.0. My BuddyPress status is below.I’m having a problem when someone is choosing a any kind of membership(I only have free and 1 paid at the moment). When they get to the billing screen they can either use Facebook or Google to login and fill in the details.
Once they do that, Buddypress redirects them to their wall. I want them to be able to continue the checkout process. I’ve tried so many things, but can’t override it.
Please help!
### WordPress Environment ### Home URL: http://www.specialtactics.global Site URL: http://www.specialtactics.global WC Version: 3.4.1 Log Directory Writable: β WP Version: 4.9.6 WP Multisite: β WP Memory Limit: 256 MB WP Debug Mode: β WP Cron: β Language: en_US External object cache: β ### Server Environment ### Server Info: Apache PHP Version: 7.1.16 - We recommend using PHP version 7.2 or above for greater performance and security. How to update your PHP version PHP Post Max Size: 128 MB PHP Time Limit: 3000 PHP Max Input Vars: 1000 cURL Version: 7.54.0 OpenSSL/1.0.2k SUHOSIN Installed: β MySQL Version: 5.6.39-cll-lve Max Upload Size: 128 MB Default Timezone is UTC: β fsockopen/cURL: β SoapClient: β DOMDocument: β GZip: β Multibyte String: β Remote Post: β Remote Get: β ### Database ### WC Database Version: 3.4.1 WC Database Prefix: wp_ MaxMind GeoIP Database: β Total Database Size: 11.24MB Database Data Size: 10.10MB Database Index Size: 1.14MB wp_woocommerce_sessions: Data: 0.04MB + Index: 0.00MB wp_woocommerce_api_keys: Data: 0.00MB + Index: 0.00MB wp_woocommerce_attribute_taxonomies: Data: 0.00MB + Index: 0.00MB wp_woocommerce_downloadable_product_permissions: Data: 0.00MB + Index: 0.00MB wp_woocommerce_order_items: Data: 0.00MB + Index: 0.00MB wp_woocommerce_order_itemmeta: Data: 0.00MB + Index: 0.01MB wp_woocommerce_tax_rates: Data: 0.00MB + Index: 0.00MB wp_woocommerce_tax_rate_locations: Data: 0.00MB + Index: 0.00MB wp_woocommerce_shipping_zones: Data: 0.00MB + Index: 0.00MB wp_woocommerce_shipping_zone_locations: Data: 0.00MB + Index: 0.00MB wp_woocommerce_shipping_zone_methods: Data: 0.00MB + Index: 0.00MB wp_woocommerce_payment_tokens: Data: 0.00MB + Index: 0.00MB wp_woocommerce_payment_tokenmeta: Data: 0.00MB + Index: 0.00MB wp_woocommerce_log: Data: 0.00MB + Index: 0.00MB ts_redirects: Data: 0.00MB + Index: 0.00MB wp_achievements: Data: 0.02MB + Index: 0.01MB wp_bp_activity: Data: 0.01MB + Index: 0.01MB wp_bp_activity_meta: Data: 0.00MB + Index: 0.01MB wp_bp_friends: Data: 0.00MB + Index: 0.00MB wp_bp_groups: Data: 0.00MB + Index: 0.00MB wp_bp_groups_groupmeta: Data: 0.00MB + Index: 0.00MB wp_bp_groups_members: Data: 0.00MB + Index: 0.00MB wp_bp_links: Data: 0.00MB + Index: 0.00MB wp_bp_links_categories: Data: 0.00MB + Index: 0.00MB wp_bp_links_linkmeta: Data: 0.00MB + Index: 0.00MB wp_bp_links_votes: Data: 0.00MB + Index: 0.00MB wp_bp_messages_drafts: Data: 0.00MB + Index: 0.00MB wp_bp_messages_labels: Data: 0.00MB + Index: 0.00MB wp_bp_messages_label_message: Data: 0.00MB + Index: 0.00MB wp_bp_messages_messages: Data: 0.00MB + Index: 0.00MB wp_bp_messages_meta: Data: 0.00MB + Index: 0.00MB wp_bp_messages_notices: Data: 0.00MB + Index: 0.00MB wp_bp_messages_recipients: Data: 0.00MB + Index: 0.00MB wp_bp_notifications: Data: 0.00MB + Index: 0.00MB wp_bp_notifications_meta: Data: 0.00MB + Index: 0.00MB wp_bp_user_blogs: Data: 0.00MB + Index: 0.00MB wp_bp_user_blogs_blogmeta: Data: 0.00MB + Index: 0.01MB wp_bp_xprofile_data: Data: 0.00MB + Index: 0.00MB wp_bp_xprofile_fields: Data: 0.03MB + Index: 0.05MB wp_bp_xprofile_groups: Data: 0.00MB + Index: 0.00MB wp_bp_xprofile_meta: Data: 0.01MB + Index: 0.02MB wp_buddyboss_media: Data: 0.00MB + Index: 0.00MB wp_buddyboss_media_albums: Data: 0.00MB + Index: 0.00MB wp_commentmeta: Data: 0.00MB + Index: 0.01MB wp_comments: Data: 0.01MB + Index: 0.01MB wp_gde_profiles: Data: 0.00MB + Index: 0.00MB wp_gde_secure: Data: 0.00MB + Index: 0.00MB wp_learndash_user_activity: Data: 0.01MB + Index: 0.03MB wp_learndash_user_activity_meta: Data: 0.04MB + Index: 0.03MB wp_links: Data: 0.00MB + Index: 0.00MB wp_options: Data: 2.97MB + Index: 0.09MB wp_pmpro_discount_codes: Data: 0.00MB + Index: 0.00MB wp_pmpro_discount_codes_levels: Data: 0.00MB + Index: 0.00MB wp_pmpro_discount_codes_uses: Data: 0.00MB + Index: 0.00MB wp_pmpro_memberships_categories: Data: 0.00MB + Index: 0.00MB wp_pmpro_memberships_pages: Data: 0.00MB + Index: 0.00MB wp_pmpro_memberships_users: Data: 0.00MB + Index: 0.01MB wp_pmpro_membership_levelmeta: Data: 0.00MB + Index: 0.00MB wp_pmpro_membership_levels: Data: 0.00MB + Index: 0.01MB wp_pmpro_membership_orders: Data: 0.00MB + Index: 0.02MB wp_pmxi_files: Data: 0.00MB + Index: 0.00MB wp_pmxi_history: Data: 0.00MB + Index: 0.00MB wp_pmxi_imports: Data: 0.00MB + Index: 0.00MB wp_pmxi_posts: Data: 0.00MB + Index: 0.00MB wp_pmxi_templates: Data: 0.00MB + Index: 0.00MB wp_postmeta: Data: 0.83MB + Index: 0.21MB wp_posts: Data: 2.47MB + Index: 0.17MB wp_pp_login_builder: Data: 0.01MB + Index: 0.00MB wp_pp_password_reset_builder: Data: 0.01MB + Index: 0.00MB wp_pp_registration_builder: Data: 0.01MB + Index: 0.00MB wp_revslider_css: Data: 0.09MB + Index: 0.00MB wp_revslider_layer_animations: Data: 0.00MB + Index: 0.00MB wp_revslider_navigations: Data: 0.00MB + Index: 0.00MB wp_revslider_sliders: Data: 0.02MB + Index: 0.00MB wp_revslider_slides: Data: 0.18MB + Index: 0.00MB wp_revslider_static_slides: Data: 0.00MB + Index: 0.00MB wp_signups: Data: 0.00MB + Index: 0.00MB wp_social_users: Data: 0.00MB + Index: 0.00MB wp_termmeta: Data: 0.00MB + Index: 0.01MB wp_terms: Data: 0.00MB + Index: 0.01MB wp_term_relationships: Data: 0.00MB + Index: 0.01MB wp_term_taxonomy: Data: 0.00MB + Index: 0.01MB wp_usermeta: Data: 0.05MB + Index: 0.04MB wp_users: Data: 0.00MB + Index: 0.01MB wp_waiting: Data: 0.00MB + Index: 0.00MB wp_wc_download_log: Data: 0.00MB + Index: 0.00MB wp_wc_webhooks: Data: 0.00MB + Index: 0.00MB wp_wfBadLeechers: Data: 0.00MB + Index: 0.00MB wp_wfBlockedCommentLog: Data: 0.00MB + Index: 0.00MB wp_wfBlockedIPLog: Data: 0.00MB + Index: 0.00MB wp_wfBlocks7: Data: 0.00MB + Index: 0.00MB wp_wfConfig: Data: 0.36MB + Index: 0.01MB wp_wfCrawlers: Data: 0.00MB + Index: 0.00MB wp_wfFileChanges: Data: 0.00MB + Index: 0.00MB wp_wfFileMods: Data: 0.48MB + Index: 0.11MB wp_wfHits: Data: 0.14MB + Index: 0.03MB wp_wfHoover: Data: 0.00MB + Index: 0.00MB wp_wfIssues: Data: 0.00MB + Index: 0.00MB wp_wfKnownFileList: Data: 0.97MB + Index: 0.12MB wp_wfLeechers: Data: 0.00MB + Index: 0.01MB wp_wfLiveTrafficHuman: Data: 0.00MB + Index: 0.00MB wp_wfLocs: Data: 0.00MB + Index: 0.00MB wp_wfLogins: Data: 0.01MB + Index: 0.00MB wp_wfNet404s: Data: 0.00MB + Index: 0.00MB wp_wfNotifications: Data: 0.00MB + Index: 0.00MB wp_wfPendingIssues: Data: 0.00MB + Index: 0.00MB wp_wfReverseCache: Data: 0.00MB + Index: 0.00MB wp_wfScanners: Data: 0.00MB + Index: 0.00MB wp_wfSNIPCache: Data: 0.00MB + Index: 0.00MB wp_wfStatus: Data: 0.06MB + Index: 0.03MB wp_wfVulnScanners: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_category: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_form: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_lock: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_master: Data: 0.02MB + Index: 0.00MB wp_wp_pro_quiz_prerequisite: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_question: Data: 1.24MB + Index: 0.03MB wp_wp_pro_quiz_statistic: Data: 0.01MB + Index: 0.00MB wp_wp_pro_quiz_statistic_ref: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_template: Data: 0.00MB + Index: 0.00MB wp_wp_pro_quiz_toplist: Data: 0.00MB + Index: 0.00MB wp_wsluserscontacts: Data: 0.00MB + Index: 0.00MB wp_wslusersprofiles: Data: 0.00MB + Index: 0.00MB ### Post Type Counts ### attachment: 121 bmt-member-type: 4 bp-email: 32 cdfc: 1 condition_group: 1 custom_css: 1 customize_changeset: 9 forum: 1 jetpack_migration: 2 mc4wp-form: 1 nav_menu_item: 33 page: 39 post: 24 product: 12 revision: 1003 scheduled-action: 16 sfwd-certificates: 1 sfwd-courses: 7 sfwd-lessons: 36 sfwd-quiz: 38 sfwd-topic: 147 shop_order: 7 shop_subscription: 5 sidebar: 1 sp_wps_shortcodes: 1 topic: 4 wc_membership_plan: 6 wcps: 1 woocarousel: 1 wpachievements: 3 wpcf7_contact_form: 1 wpe_product_carousel: 1 yith_wcps_type: 1 ### Security ### Secure connection (HTTPS): β Your store is not using HTTPS. Learn more about HTTPS and SSL Certificates. Hide errors from visitors: β ### Active Plugins (50) ### Addons for WPBakery Page Builder: by Livemesh β 1.9.1 Akismet Anti-Spam: by Automattic β 4.0.7 bbPress: by The bbPress Community β 2.5.14 Better Search Replace: by Delicious Brains β 1.3.2 Boss for LearnDash: by BuddyBoss β 1.3.0 BP Redirect To Profile: by Brajesh Singh β 1.2.2 BuddyBoss Inbox: by BuddyBoss β 1.1.3 BuddyBoss Media: by BuddyBoss β 3.2.4 BuddyBoss One Click Installer: by BuddyBoss β 1.0.6 BuddyBoss Wall: by BuddyBoss β 1.3.3 BuddyPress for LearnDash: by BuddyBoss β 1.2.4 BuddyPress Member Types: by BuddyBoss β 1.1.2 BuddyPress: by The BuddyPress Community β 3.0.0 Contact Form 7: by Takayuki Miyoshi β 5.0.2 Force HTTPS: by LittleBizzy β 1.0.6 Google Doc Embedder: by Kevin Davis Dan Lester β 2.6.4 Insert or Embed Articulate Content into WordPress Trial: by Brian Batt β 4.292 WPBakery Page Builder: by Michael M - WPBakery.com β 5.4.7 LearnDash Content Cloner: by WisdmLabs β 1.2.2 LearnDash & bbPress Integration: by LearnDash β 2.0.2.1 LearnDash Course Grid: by LearnDash β 1.4.1 LearnDash ProPanel: by LearnDash β 2.1.3 LearnDash WooCommerce Integration: by LearnDash β 1.4.0 β Not tested with the active version of WooCommerce Mega Addons For Visual Composer: by Nasir β 2.2 Nextend Social Login: by Nextendweb β 3.0.10 Nextend Social Login Pro Addon: by Nextendweb β 3.0.8 WooCommerce Product Carousel Slider: by ADL Plugins β 3.0.2 β Not tested with the active version of WooCommerce Restrict Content: by Pippin Williamson β 2.2.3 Slider Revolution: by ThemePunch β 5.4.7.3 LearnDash LMS: by LearnDash β 2.5.8.2 Simple Buddypress Profile Privacy: by Justin Hansen β 0.7.7 String Locator: by Clorith β 2.3.0 Theme My Login: by Jeff Farthing β 6.4.16 Uncanny LearnDash Toolkit: by Uncanny Owl β 2.4.2 Uncanny LearnDash Toolkit Pro: by Uncanny Owl β 2.3.1 UpdraftPlus - Backup/Restore: by UpdraftPlus.Com DavidAnderson β 1.14.11 Essential WPBakery Page Builder (formerly Visual Composer) Addons: by themebon β 1.9.1 Waiting: by Plugin Builders β 0.4.5 WC4BP -> WooCommerce BuddyPress Integration (Premium): by ThemeKraft β 3.1.4 β Not tested with the active version of WooCommerce WC4BP -> Subscriptions: by ThemeKraft β 1.1.0 β Not tested with the active version of WooCommerce WC4BP -> BuddyPress xProfile Checkout Manager: by ThemeKraft β 1.3.0 β Not tested with the active version of WooCommerce WooCommerce Colors: by WooThemes β 1.0.7 β Not tested with the active version of WooCommerce WooCommerce PayPal Express Checkout Gateway: by WooCommerce β 1.5.5 WooCommerce Stripe Gateway: by WooCommerce β 4.1.6 WooCommerce Memberships: by SkyVerge β 1.10.4 WooCommerce Social Login: by SkyVerge β 2.5.2 WooCommerce Subscriptions: by Prospress Inc. β 2.2.21 WooCommerce: by Automattic β 3.4.1 β 3.4.2 is available WP File Manager: by mndpsingh287 β 2.7 WP Rollback: by WordImpress β 1.5 ### Settings ### API Enabled: β Force SSL: β Currency: USD ($) Currency Position: left Thousand Separator: , Decimal Separator: . Number of Decimals: 2 Taxonomies: Product Types: course (course) external (external) grouped (grouped) simple (simple) subscription (subscription) variable (variable) variable subscription (variable-subscription) Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog) exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-3) rated-4 (rated-4) rated-5 (rated-5) ### WC Pages ### Shop base: β Page not set Cart: #562 - /cart/ Checkout: #9648 - /woocommerce-checkout/ My account: #9671 - /membership/ Terms and conditions: β Page not set ### Theme ### Name: Boss. Child Theme Version: 2.4.3 Author URL: http://www.buddyboss.com Child Theme: β Parent Theme Name: Boss. Parent Theme Version: 2.4.6 Parent Theme Author URL: https://www.buddyboss.com WooCommerce Support: β ### Templates ### Overrides: β ### subscriptions ### WCS_DEBUG: β No Subscriptions Mode: β Live Subscriptions Template Theme Overrides: β Report Cache Enabled: β Yes Cache Update Failures: β 0 failureI’ve seen that this problem crops up a lot, but I can’t seem to find a solution that works…
I have Membership Pro 2 and BuddyPress installed. I’m using the BuddyPress registration form with extra profile fields. Currently, the registration form asks for the Username and Name (display name in BP terms). Obviously, this is really confusing for new members when they’re registering so I need to remove one of these. I’ve tested it out and the WP Username is the one that seems to be used throughout the site, so it would be good just to hide/remove the BP Name. I can hide the field with CSS, but then there is an error and the form won’t submit due to the missing field.
Do I just need to find the code to allow the form to be submitted without this required field?
I’ve seen people use the two plugins:
BP XProfile WordPress User Sync
But I can’t see how these can work with this particular issue?
Any help is appreciated.
Hey guys,
first of all, awesome forum! I’ve already solved so many of my issues simply by reading the many helpful answers – hence never had the need to post anything myself, but now I’m a bit stuck.
Here’s what I wanted to do: Put a new profile group in a separate bp profile menu tab and make it visible to both, logged in as well as logged out users. Now, it works perfectly fine, except for the fact that logged out users for some reason get to see my personal profile group under my custom tab instead of the new profile group – which is displayed correctly for me as well as other logged in users.
Here’s my code:
/** BP Profile Tab Visibility */ function bpfr_hide_top_nav() { if( !is_user_logged_in() ) { // bp topnav items to hide bp_core_remove_nav_item( 'activity' ); bp_core_remove_nav_item( 'friends' ); bp_core_remove_nav_item( 'groups' ); bp_core_remove_nav_item( 'forums' ); bp_core_remove_nav_item( 'media' ); bp_core_remove_nav_item( 'docs' ); bp_core_remove_nav_item( 'location' ); //bp subnav (my activities, my groups, etc) bp_core_remove_subnav_item( 'activity', 'activity' ); bp_core_remove_subnav_item( 'activity', 'friends' ); bp_core_remove_subnav_item( 'activity', 'favorites' ); bp_core_remove_subnav_item( 'activity', 'groups' ); bp_core_remove_subnav_item( 'activity', 'mentions' ); bp_core_remove_subnav_item( 'activity', 'media' ); bp_core_remove_subnav_item( 'activity', 'docs' ); bp_core_remove_subnav_item( 'activity', 'comments' ); } } add_action( 'bp_ready', 'bpfr_hide_top_nav', 10 ); /** BP Tab Order Profile and Tab Rename */ function bpex_primary_nav_tabs_position() { buddypress()->members->nav->edit_nav( array( 'position' => 2, ), 'activity' ); buddypress()->members->nav->edit_nav( array( 'position' => 1, ), 'profile' ); buddypress()->members->nav->edit_nav( array( 'position' => 3, ), 'messages' ); buddypress()->members->nav->edit_nav( array( 'position' => 4, ), 'notifications' ); buddypress()->members->nav->edit_nav( array( 'position' => 5, ), 'friends' ); buddypress()->members->nav->edit_nav( array( 'position' => 6, ), 'groups' ); buddypress()->members->nav->edit_nav( array( 'position' => 7, ), 'forums' ); buddypress()->members->nav->edit_nav( array( 'position' => 8, ), 'criticalreview' ); buddypress()->members->nav->edit_nav( array( 'position' => 9, ), 'docs' ); buddypress()->members->nav->edit_nav( array( 'position' => 10, ), 'media' ); buddypress()->members->nav->edit_nav( array( 'position' => 11, ), 'location' ); buddypress()->members->nav->edit_nav( array( 'position' => 12, ), 'orders' ); buddypress()->members->nav->edit_nav( array( 'position' => 13, ), 'settings' ); } add_action( 'bp_setup_nav', 'bpex_primary_nav_tabs_position', 999 ); /** Put Critical Review Profile Group in BP Tab */ function buddydev_modifyy_user_profile_tab() { bp_core_new_nav_item( array( 'name' => 'Critical Review', 'slug' => 'criticalreview', 'screen_function' => 'buddydev_screen_profile_data', 'default_subnav_slug' => 'criticalreview-sub', 'show_for_displayed_user' => true, )); } add_action( 'bp_setup_nav', 'buddydev_modifyy_user_profile_tab', 8 ); function buddydev_screen_profile_data() { //filter loop add_filter( 'bp_after_has_profile_parse_args', 'buddydev_filter_args_for_profile_group' ); //load loop add_action( 'bp_template_content', 'buddydev_show_profile_group_data'); bp_core_load_template( 'members/single/plugins'); } function buddydev_filter_args_for_profile_group( $args ) { ///CHANGE IT $args['profile_group_id'] = '6'; //Your Profile Group ID Here return $args; } //Load the loop function buddydev_show_profile_group_data() { $profileslug = bp_get_profile_slug(); // if ( bp_is_my_profile() ) : // echo "Edit under Profile"; // endif; bp_get_template_part( 'members/single/profile/profile-loop' ); } function hide_profile_group( $grpid ) { if ( is_user_logged_in() && !bp_is_profile_edit() ) { $myfield = xprofile_get_field_data( 'Critical Review' ); $grpid['exclude_groups'] = '6'; } return $grpid; } add_filter( 'bp_after_has_profile_parse_args', 'hide_profile_group' );A few comments:
Most of the essential code is based on this threat. I am not really a coder myself, but usually I understand what the functions are doing.
For now I commented `// if ( bp_is_my_profile() ) :
// echo “Edit under Profile”;
// endif;` out, because if I leave it in, for some reason then also logged-in users only see the personal profile group instead of the Critical Review one?!Also, I’m not entirely sure about the use of the last function and its use / relevance, because it doesn’t seem to affect anything. This might however have to do with the fact that in order to avoid duplication of the Critical Review profile group under the actual profile tab, I’ve hidden the profile group via CSS.
Finally, I’m running the latest WP and BP installs and you can have a look at the described behavior here. Interestingly, as you can see in this instance, the profile fields are actually adjusted to my CSS for the Critical Review profiles group – but the actual content doesn’t show correctly.
Now, if any of you could help me out, I would highly appreciate it!
Thank you so much in advance! π
Hi, I’m using the plugin BuddyPress Admin Only Profile Fields to hide certain xprofile fields, I have quite a few, when viewing the admin EDIT (front view) page, it shows a blank white screen. I cannot figure out whats wrong with the site, if anyone can help I’d greatly appreciate it.
wp v4.6.1
bp v2.7.0
Theme: Twenty Sixteen
Cant provide link, it is on my local.
I am web developer.Hello, I would like to ask you about xprofile fields for users.
I have add 2 profile fields groups, with fields.
Right now I am wondering if it is possible to hide them from:
Single profile page. From show tab and from EDIT tab.
From dashboard profile edit page.
From custom profile fields.
From tabs every where.I have tried to use this code:
function bpfr_hide_profile_field_group( $retval ) {
$retval[‘exclude_groups’] = ‘0,1,2’;
return $retval;
}
It hide fields only from show on single profile page but not from edit.
Thank you very much.
Very appreciate your help.Topic: filter xprofile fields
Is there a way to filter out some xprofile fields to be displayed on the members profile page? Some fields I want to hide as default.
Under certain circumstances, there is an infinite loop inside the
bp_legacy_theme_new_activity_comment()function. Specifically, when all of thesecondary_item_idfields are zero, the$parent_idwill continually be set to zero. An infinite loop ensues and eventually the script will time out. This causes new activity items to not display until the page is refreshed, as mentioned here: https://buddypress.org/support/topic/activity-comments-post-blank-until-refresh/.This error happens when attempting to add a comment to a group post. I believe this is a similar problem as the one expressed here: https://buddypress.org/support/topic/activity-comments-post-blank-until-refresh/
For information:
- WordPress
4.5.3 - BuddyPress
2.6.1.1 - Single site install in web root
- There are indeed other plugins activated on this site. The full list is below. This site is for a client, and I’m unsure of which plugins can be safely deactivated to test.
- We’re using a customized theme, but I have tested with the TwentySixteen theme and found the same results.
- The core BuddyPress files have not been modified to my knowledge.
- The site is hosted on Page.ly, but I can reproduce the problems in a local VVV install
- The live site is http://www.lifeofdad.com/
I believe that this may be a problem inside BuddyPress itself, as the function with the infinite loop is part of BuddyPress. The Javascript that makes the Ajax request is part of the BuddyPress Wall plugin, but from what I can tell the problem is in the aforementioned
bp_legacy_theme_new_activity_comment()function.My specific concern is this loop:
// Load the new activity item into the $activities_template global. bp_has_activities( 'display_comments=stream&hide_spam=false&show_hidden=true&include=' . $comment_id ); // Swap the current comment with the activity item we just loaded. if ( isset( $activities_template->activities[0] ) ) { $activities_template->activity = new stdClass(); $activities_template->activity->id = $activities_template->activities[0]->item_id; $activities_template->activity->current_comment = $activities_template->activities[0]; // Because the whole tree has not been loaded, we manually // determine depth. $depth = 1; $parent_id = (int) $activities_template->activities[0]->secondary_item_id; while ( $parent_id !== (int) $activities_template->activities[0]->item_id ) { $depth++; $p_obj = new BP_Activity_Activity( $parent_id ); $parent_id = (int) $p_obj->secondary_item_id; } $activities_template->activity->current_comment->depth = $depth; }I’ve run XDebug locally to inspect the items in the loop as it is running. If some of the raw variable data is required, I can provide that.
I have tried making some changes to the code in this loop to prevent the infinite loop from occurring. While successful in that endeavor with a few tweaks, the result is that the comment sent back through the Ajax response is the wrong comment, and a page refresh is still needed.
I considered filing a bug in Trac, but I wasn’t certain whether something else could possibly be interfering.
+--------------------------------------+--------+-----------+---------+ | name | status | update | version | +--------------------------------------+--------+-----------+---------+ | akismet | active | none | 3.1.11 | | all-in-one-seo-pack | active | available | 2.3.7 | | appbuddy | active | available | 2.0.7 | | appcamera | active | available | 2.0.0 | | appfbconnect | active | none | 2.3.0 | | apppresser | active | none | 2.5.0 | | apppush | active | available | 2.1.0 | | appshare | active | none | 2.1.0 | | appswiper | active | available | 2.2.1 | | bp-profile-search | active | none | 4.5.2 | | buddypress | active | none | 2.6.1.1 | | buddypress-activity-plus | active | none | 1.6.4 | | bp-moderation | active | none | 0.1.7 | | buddypress-nocaptcha-register-box | active | none | 1.1.3 | | buddypress-toolbar | active | none | 1.6.0 | | buddypress-wall | active | none | 0.9.4 | | buddypress-xprofile-image-field | active | none | 2.0.1 | | category-posts | active | none | 4.6.1 | | contact-form-7 | active | none | 4.4.2 | | contact-form-7-to-database-extension | active | none | 2.10.20 | | cubell-themes-functionality | active | none | 3.1 | | envato-wordpress-toolkit | active | none | 1.7.3 | | hashbuddy | active | none | 1.5.2 | | login-with-ajax | active | none | 3.1.6 | | mailchimp-for-wp | active | none | 3.1.11 | | nav-menu-roles | active | none | 1.8.2 | | nextend-facebook-connect | active | none | 1.5.9 | | buddypress-media | active | none | 4.0.4 | | vine-embed | active | none | 0.2 | | wds-lod-automatic-friends | active | none | 0.1.0 | | wds-lod-base | active | none | 0.1.0 | | wds-lod-bp | active | none | 0.1.0 | | wds-lod-post-types | active | none | 0.1.0 | | wds-lod-widgets | active | none | 0.1.0 | | wordpress-importer | active | none | 0.6.1 | +--------------------------------------+--------+-----------+---------+ - WordPress
