• Resolved jayme2604

    (@jayme2604)


    Hello Ultimate Member Support,

    When an user updates their profile form, I would like to let Ultimate Member send an email to only the admin. For that, I have added a Snippet with your code: https://github.com/MissVeronica/UM-Admin-User-Profile-Update-Email/blob/main/source.php. If I go to Ultimate Member email settings, I do see the template appearing “Profile is updated email”, but it’s not working.

    A second question, when updating the profile form, the user will be redirecting back to the homepage. But I would like to let the user stay on the same tab, on the same page. I have already checked user management, but I can’t set a manual redirect link in there.

    Hopefully you can help me out here with above 2 questions.

    Thanks again!

Viewing 5 replies - 16 through 20 (of 20 total)
  • @jayme2604

    Try to copy with your FTP client the plugin email template file from:
    .../plugins/um-admin-user-profile-update-email-main/profile_is_updated_email.php

    to your UM directory:
    .../plugins/ultimate-member/templates/email/profile_is_updated_email.php

    Thread Starter jayme2604

    (@jayme2604)

    @missveronicatv

    Ah my bad, I was looking in the wrong folder. I have copied the file and now it works! Thank you so much for the great support!

    Thread Starter jayme2604

    (@jayme2604)

    @missveronicatv

    A follow up on this. When I update an user from the admin console (wp-admin) and I click on “Update profile”, then the following error appears:

    Fatal error: Uncaught Error: Call to undefined function custom_profile_is_updated_email() in /home/public/sites/xxx.nl/wp-content/plugins/um-admin-user-profile-update-email-main/um-admin-user-profile-update-email.php:105 Stack trace: #0 /home/public/sites/xxx.nl/wp-includes/class-wp-hook.php(308): UM_Admin_Email_Profile_Update->custom_profile_is_updated_email_backend() #1 /home/public/sites/xxx.nl/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters() #2 /home/public/sites/xxx.nl/wp-includes/plugin.php(517): WP_Hook->do_action() #3 /home/public/sites/xxx.nl/wp-includes/user.php(2461): do_action() #4 /home/public/sites/xxx.nl/wp-includes/user.php(2582): wp_insert_user() #5 /home/public/sites/xxx.nl/wp-admin/includes/user.php(233): wp_update_user() #6 /home/public/sites/xxx.nl/wp-admin/user-edit.php(170): edit_user() #7 /home/public/sites/xxx.nl/wp-admin/profile.php(18): require_once('...') #8 {main} thrown in?/home/public/sites/xxx.nl/wp-content/plugins/um-admin-user-profile-update-email-main/um-admin-user-profile-update-email.php?on line?105

    There is no need to sent an email when an admin updates the user via the admin console. Could I add this in the code somewhere?

    Thanks again.

    @jayme2604

    I have made an update to fix the backend email in version 3.3.0

    Yes you can comment line 28 in
    plugins/um-admin-user-profile-update-email-main/um-admin-user-profile-update-email.php

    //add_action( 'profile_update', array( $this, 'custom_profile_is_updated_email_backend' ), 10, 3 );

    Thread Starter jayme2604

    (@jayme2604)

    @missveronicatv

    Yes, the error is gone now. Thanks! ??

Viewing 5 replies - 16 through 20 (of 20 total)
  • The topic ‘Profile form email to admin’ is closed to new replies.