Replies
- Hervé on May 11, 2018 at 2:20 pm in reply to: to the connection of an existing member: change (role, plan) #15020
Hello Brajesh
This poses a real problem for the members!
Is it difficult or can not you do it?Regards
- This reply was modified 6 years, 6 months ago by Hervé.
- Hervé on May 3, 2018 at 1:05 pm in reply to: to the connection of an existing member: change (role, plan) #14883
Hello Brajesh
Sorry! I forgot to say that it is more urgent because there are members who remain in the subscriber state (a little complicated to explain but I think it is due to the change of programming with an existing site).
This program would allow me to solve this too
Regards - Hervé on April 30, 2018 at 11:00 am in reply to: to the connection of an existing member: change (role, plan) #14825
Hello Brajesh
A little reminder if you could help me
Have a good day
Regards - Hervé on April 23, 2018 at 8:37 am in reply to: Activities : no storage, erase all activities automatically every year #14728
Hello Brajesh,
cool it works 🙂
It is therefore quite different from the old method.For registration of the match in function buddydev_exclude_activity_types_from_recording( &$activity ) { … I put
$excluded_types = array( 'friendship_created', 'new_member' );
Do I have to put too
$excluded_types = array( 'friendship_accepted,friendship_created' ...
in function buddydev_remove_activity_filters_from_dropdown( $filters )I said my priority to receive the answer for what is most important to me, because I know that you also have priorities for work to make choices.
Regards - Hervé on April 19, 2018 at 9:03 am in reply to: Activities : no storage, erase all activities automatically every year #14632
Hello Brajesh
I misspoke because it does not work as I thought
I do not want to record ‘friendship_created’, ‘new_member’, ‘updated_profile’
Ok with https://buddydev.com/buddypress/disallowing-activity-recording-for-components-or-some-activity-types-in-buddypress/
It is therefore necessary to hide the term in the selector
https://screenshots.firefox.com/QPEVCbltOA8Mrpc6/nullI had a code similar to this one that worked before:
add_filter( 'bp_after_has_activities_parse_args', 'activites_affiche_infos' ); function activites_affiche_infos( $retval ) { // if ( bp_is_active( 'activity' ) ) { $retval['action'] = array( 'activity_comment', 'activity_update', //'created_group', //'friendship_created', 'joined_group', 'last_activity', //'new_avatar', 'new_blog_comment', 'new_blog_post', //'new_member', 'updated_profile' ); return $retval; // } }
It does not work anymore.
I think there have been changes in buddypress !!
this is not urgent
I prefer to have help on https://buddydev.com/support/forums/topic/to-the-connection-of-an-existing-member-change-role-plan/Regards
- Hervé on April 17, 2018 at 4:04 pm in reply to: to the connection of an existing member: change (role, plan) #14575
Hello Brajesh
Ok forget the only line (do_action(‘arm_apply_plan_to_member’, $num_plan_payant_1an, $user_id);) on the armember component (which works in your other code). I have to do a program to solve a role loss problem
The idea is at the moment of connection (That’s when I can not do it, I think), check if the member has
* a photo
* all mandatory fields filled
* a subscriber role
* a special value for an xprofile fieldIf yes I change the role of the member (member0)
Regards
- Hervé on April 17, 2018 at 3:55 pm in reply to: Activities : no storage, erase all activities automatically every year #14572
Hello Brajesh
1/ ok
2/ ok
3/ yes
Thanks - Hervé on April 17, 2018 at 9:21 am in reply to: Activities : no storage, erase all activities automatically every year #14559
Hello Brajesh,
First of all thank you for the answer. I was long because I needed to be clearer.
1 / it works but what does it mean ” //reset either component or type, both will cause a failure in saving activity”?
If I understand correctly, it’s a question of not using the 2 snippets at the same time2 / actually i want to be very careful using sql.
I found a plugin https://wordpress.org/plugins/bulk-delete/ which will be able to use me to suppress all the members (and therefore activities) of a test site
The 2nd solution I found to delete people who register on the site but never finish their registrationfunction spammersdeletion() { global $wpdb; $from = strtotime('-30 day', time()); $wpdb->query('DELETE FROM wp_users WHERE DATE(user_registered) < "'.date('Y-m-d', $from).'"AND user_status = "2"'); } add_action('init','spammersdeletion');
3 / I do not want to see in the selector
a) Items deleted from storage$excluded_types = array( 'friendship_created', 'new_member' );
b) updating the profile “updated_profile”
Regards - Hervé on April 17, 2018 at 8:10 am in reply to: to the connection of an existing member: change (role, plan) #14558
Hello
Help me please
Regards - Hervé on April 10, 2018 at 4:31 pm in reply to: [Resolved] insert a value into my new xprofile numeric field #14392
Hi Brajesh
Thank you it works.
Great 🙂
If I understand correctly, I can use add_action (‘bp_core_activated_user’, ..) to do any type of action when registering a new memberand there is another hook for editing data change a profile:
“xprofile_data_before_save”BuddyPress has a lot of HOOKS
Regards