Search Results for 'buddypress'
-
AuthorSearch Results
-
March 19, 2019 at 6:56 pm #303722
lordmatt
ParticipantBingo – sounds good!
I was toying around with this and getting nowhere:
if ( !function_exists( 'bp_core_load_template' ) ) { require_once '/bp-core/bp-core-catchuri.php'; } $templates = array('bp_core_template_plugin', 'buddypress/activity/activity-loop'); $result = bp_core_load_template($templates);March 19, 2019 at 5:14 pm #303719lordmatt
ParticipantI’m guessing I could just include
./wp-content/plugins/buddypress/bp-templates/bp-nouveau/buddypress/activity/activity-loop.php?March 19, 2019 at 5:11 pm #303718Venutius
ModeratorAh sorry was assuming too much. In that case take a look at the BP Nouveau equivalent of that page in bp-templates/bp-nouveau/buddypress/activities/activity-loop.php. In nouveau the activity is generated mainly by js, you just have to recreate the right class and id structure in the page and nouveau will automatically implant the activity, no need for the loop. But this only works for the default activity settings, if you want to filter them I’m not certain how to go about doing that.
Legacy represents that old way, with page loads and a php loop. Nouveau is highly js with js fetching the content without page loads.
March 19, 2019 at 4:38 pm #303716In reply to: poor quality avatar in mobile
Venutius
ModeratorThere’s a thread which did not complete related to this, I wonder if the suggested fix would help you?
March 19, 2019 at 4:12 pm #303713In reply to: Conditional menu and BuddyPress core
superp777
ParticipantMarch 19, 2019 at 4:09 pm #303712In reply to: Conditional menu and BuddyPress core
superp777
ParticipantUpdate: Found out that the reason is BuddyPress supporting Primary Nav menu only.
Is there a way to add support for different menus as well? Thanks.March 19, 2019 at 2:42 pm #303708Venutius
ModeratorIf you were to go ahead with the idea of overloading the front page you’d need to use bp_has_activities() as part of the activity loop. You can check out how it’s used by looking at plugins/buddypress/bp-templates/bp-legacy/buddypress/activity/activity-loop.php
March 19, 2019 at 2:37 pm #303705lordmatt
ParticipantI see. I’m not fond of adding too many plugins. I know this could be done as part of the child theme. That’s what I feel would be the best approach – that would keep extra plugins away from the multisite blog owners.
The thing is, I’m having a heck of a time getting my head around the BuddyPress template stack. I have worked out I’ll need two loops – WP and BP but that’s about it.
March 19, 2019 at 1:54 pm #303697Topic: Conditional menu and BuddyPress core
in forum How-to & Troubleshootingsuperp777
ParticipantHi,
We are using Conditional menus to display a different nav menu to people inside the BuddyPress community. For some reason it does not appear on the BP Core pages and there is the Primary menu instead.
What’s the best way to tweak it?
Thanks
March 19, 2019 at 1:48 pm #303696Venutius
ModeratorRegarding changing the messages BuddyPress shows, you can create your own local translation file using the PoEdit application, see this doc:
If you really want to disable the activation emails, there’s an old plugin which I think still works:
If you have issues with it let me know.
March 19, 2019 at 1:34 pm #303695cdtrue
ParticipantThank you! That gets me half way 🙂
I still get the notification after registration about the activation link – and I do not think that the little old ladies using my site will get that they have to activate and then wait for approval (to much for them to take in).
So I now are able to stop users with the extra My Private Site-plugin and the messages sent out from BP egistration works as a charm. There is only one (Account Approved Email) that actually is sent though – I can not figure out how to get the other ones to override the BuddyPress – activation-email. And if I de-activate that e-mail no e-mail is sent at all.
Also when I click on the register-button in the registration form I get redirected to a page that says that my account needs to be activated and I have to check my e-mail to do so. I want to loose it or change the text.
If they try to log in anyway they get the wordpress opt of re-sending the activation-link. Same thing here – preferably change the text.
But where do I find the texts? I guess the re-direct page is automated from BP, the other one is from WP.
Any tips?
March 19, 2019 at 1:20 pm #303694Venutius
ModeratorYou could just overload the buddypress/groups/single/cover-image-header.php file for your bp theme to display the new fields you have added.
March 19, 2019 at 7:52 am #303690In reply to: Search activity from title or member name
Venutius
ModeratorYou can enable search for names by putting this code in your child themes functions.php:
add_filter( 'bp_activity_get_include_user_search', 'venutius_add_name_to_search' ); function venutius_add_name_to_search( $setting ) { return true; }Unfortunately there’s not a similar filter for the title, you could raise a feature request for this on https://buddypress.trac.wordpress.org/
March 19, 2019 at 12:01 am #303685In reply to: How to REMOVE “This field can be seen by:”
chris19731973
Participant{RESOLVED} : How to REMOVE “This field can be seen by:” ?
In the folder of the Theme, add the code below at the end of the file called style.css :
For me in Localhost : C:\xampp\htdocs\buddypressdivi2\wp-content\themes\Divi\Style.css.field-visibility-settings-toggle{display:none!important;}
In Users/Profile Fields of WP-Admin, set the fields like below :
Visibility = Everyone
and Allow members to overrideFor information, the visibility of “This field can be seen by: All Members/Everyone/…” will be removed in both the Registration page & Edit Profile page … except for the fields (Required) Name …
It’s my first time on this BP Forum, please how to add “RESOLVED” ?
Thank you …March 18, 2019 at 11:44 pm #303683In reply to: How to REMOVE “This field can be seen by:”
chris19731973
Participant{RESOLVED} : How to REMOVE “This field can be seen by:” ?
In the folder of the Theme, add the code below at the end of the file called style.css :
For me in Localhost : C:\xampp\htdocs\buddypressdivi2\wp-content\themes\Divi\Style.css.field-visibility-settings-toggle{display:none!important;}
For information, the visibility of “This field can be seen by: All Members/Everyone/…” will be removed in both the Registration page & Edit Profile page ….
March 18, 2019 at 11:23 pm #303681In reply to: How to REMOVE “This field can be seen by:”
chris19731973
ParticipantIn the site below, they copy the code to style.css file …
https://buddypress.org/support/topic/how-to-remove-this-field-can-be-seen-by/
You could download a plugin like this: https://wordpress.org/extend/plugins/safecss/ and add these lines of css to your style sheet, or If you have a created a child theme, you can just add these lines to your style.css file.field-visibility-settings-toggle { display:none; } .field-visibility-settings-notoggle { display:none; }I don’t have the style.css file in my Theme but these 2 files instead :
editor-style.css
theme-customizer-controls-stylesPlease do you know which CSS files need to be added or modified ?
March 18, 2019 at 11:04 pm #303680In reply to: How to REMOVE “This field can be seen by:”
chris19731973
ParticipantFrom another site, they add the code below to CSS files (but I don’t know the names of these files) :
https://alkaweb.ticksy.com/ticket/1389627/
That’s coming from BuddyPress, CSS will do the job:
.field-visibility-settings-toggle{display:none!important;}
Please do you know the files (in buddypress or in the Theme folder?) ?
March 18, 2019 at 10:51 pm #303678In reply to: How to REMOVE “This field can be seen by:”
chris19731973
ParticipantIt doesn’t work for me …
What has been changed ? see below :
‘<span class=”current-visibility-level”>’ has been replaced by
<span class=”current-visibility-level” style=”display:none;”>’ .
in the 2 files below :wp-content/themes/your-child-theme/buddypress/members/register.php’wp-content/themes/your-child-theme/buddypress/members/single/profile/edit.php’
March 18, 2019 at 4:10 pm #303674In reply to: How to REMOVE “This field can be seen by:”
chris19731973
ParticipantNow, I can read the message below when visitors choose “Register” :
Create an Account
Parse error: syntax error, unexpected ‘<‘ in C:\xampp\htdocs\buddypressdivi2\wp-content\themes\Divi\buddypress\members\register.php on line 189I removed the “Visibility” codes and the new code of the register.php file is :
Line 183 : */
Line 184 : do_action( ‘bp_custom_profile_edit_fields_pre_visibility’ );
Line 185 :
Line 186 :
Line 187 :
Line 188 : <?php
Line 189 :
Line 190 :
Line 191 : /**March 18, 2019 at 3:40 pm #303673zoleest
ParticipantStill not worked, but I found out a not too elegant solution. As far as I understand there is an order how the hooks run. There is a hook in class-buddypress.php
add_action( 'bp_core_signup_user', array( $this, 'subscribe_from_form' ), 10, 4 );so I added to my hooks 11, 4 so this is my code now:function xprofile_sync_wp_profile2( $user_id = 0 ) { // Bail if profile syncing is disabled if ( bp_disable_profile_sync() ) { return true; } if ( empty( $user_id ) ) { $user_id = bp_loggedin_user_id(); } if ( empty( $user_id ) ) { return false; } global $wpdb; // Get name from x-fields $display_name = xprofile_get_field_data('Név',$user_id ); $wpdb->query( $wpdb->prepare( "UPDATE wphu_users SET display_name = '%s' WHERE ID = %d", $display_name, $user_id ) ); } add_action( 'xprofile_updated_profile', 'xprofile_sync_wp_profile2', 11, 4); add_action( 'bp_core_signup_user', 'xprofile_sync_wp_profile2', 11, 4); add_action( 'bp_core_activated_user', 'xprofile_sync_wp_profile2', 11, 4);And fortunately it works now 🙂 I don’t know if this is a correct way, but work, so I’m okay with it.
March 18, 2019 at 1:04 pm #303669In reply to: How to REMOVE “This field can be seen by:”
Venutius
ModeratorThen you can overload the
edit.phpand ‘register.php` files and remove that attribute.get ftp access to your site and location
wp-content/plugins/buddypress/bp-templates/bp-legacy/members/register.php
wp-content/plugins/buddypress/bp-templates/bp-legacy/members/single/profile/edit.phpin these files locate and remove:
<?php if ( bp_current_user_can( 'bp_xprofile_change_field_visibility' ) ) : ?> <p class="field-visibility-settings-toggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"><span id="<?php bp_the_profile_field_input_name(); ?>-2"> <?php printf( __( 'This field can be seen by: %s', 'buddypress' ), '<span class="current-visibility-level">' . bp_get_the_profile_field_visibility_level_label() . '</span>' ); ?> </span> <button type="button" class="visibility-toggle-link" aria-describedby="<?php bp_the_profile_field_input_name(); ?>-2" aria-expanded="false"><?php _ex( 'Change', 'Change profile field visibility level', 'buddypress' ); ?></button> </p> <div class="field-visibility-settings" id="field-visibility-settings-<?php bp_the_profile_field_id() ?>"> <fieldset> <legend><?php _e( 'Who can see this field?', 'buddypress' ) ?></legend> <?php bp_profile_visibility_radio_buttons() ?> </fieldset> <button type="button" class="field-visibility-settings-close"><?php _e( 'Close', 'buddypress' ) ?></button> </div> <?php else : ?> <div class="field-visibility-settings-notoggle" id="field-visibility-settings-toggle-<?php bp_the_profile_field_id() ?>"> <?php printf( __( 'This field can be seen by: %s', 'buddypress' ), '<span class="current-visibility-level">' . bp_get_the_profile_field_visibility_level_label() . '</span>' ); ?> </div> <?php endif ?>Then place these modified files in `wp-content/themes/your-child-theme/buddypress/members/register.php’ and
`wp-content/themes/your-child-theme/buddypress/members/single/profile/edit.php’March 18, 2019 at 12:53 pm #303668In reply to: How to REMOVE “This field can be seen by:”
chris19731973
Participantin Settings>>BuddyPress>>Options, I use “BuddyPress Legacy” BP Template …
March 18, 2019 at 12:10 pm #303665In reply to: Groups visibility by role
Venutius
ModeratorI think this is possible to to but would require quite a bit of additional coding on your part, no exisitng plugin would do this.
So for example in the file
buddypress/groups/groups-loop.phpthere is the call tobp_has_members(). It’s possible to add to this theinclude=argument where you can choose which groups will be found. so you could add a function to this file which checks the user role and inputs only the groups that they can see.However you’d need additional function to allow you to add your groups to a groups/role list and keep that updaded when new groups are added. Then you could also create a function that adds new groups to this list on creation based on the member role. I’d be tempted to do this using group types but there’s a few options on exactly how this would be implemented.
So it’s not an easy fix and would require custom coding.
March 18, 2019 at 11:50 am #303663In reply to: How to REMOVE “This field can be seen by:”
Venutius
ModeratorWhich BP Template are you using? Youcan see this in Settings>>BuddyPress>>Options.
March 18, 2019 at 7:28 am #303662In reply to: Is this possible?
Venutius
ModeratorThere’s an old plugin called BuddyPress Links which allows members to add links to a links directory and then other members can vote on those links. I think this would probably serve a similar function to what you want. However, it’s out of date and throws a lot of errors. I’ve been working on updating this and have asked the developer the code can be updated. I think for your requirement it would still need some changes so it recognises videos and embeds the video instead of a static thumbnail for the site. I think this is the closest BP has got to delivering what you want easily.
Alternatively there’s MediaPress which allows video links to be added to video galleries. You can also have a sitewide gallery that everyone can add videos to, this could serve as a basis for what you are looking for.
-
AuthorSearch Results