• Resolved y2cjr

    (@y2cjr)


    Hi there,

    Thanks for the great plugin!

    I have a new registration alert email going to my admin inbox by using the following code in my functions.php file:

    // WooCommerce New Customer Admin Notification Email
    function new_customer_registered_send_email_admin($user_login) {
    ob_start();
    do_action('woocommerce_email_header', 'New customer registered');
    $email_header = ob_get_clean();
    ob_start();
    do_action('woocommerce_email_footer');
    $email_footer = ob_get_clean();
    
    woocommerce_mail(
    get_bloginfo('admin_email'),
    get_bloginfo('name').' - New customer registered',
    $email_header.'<p>The user '.esc_html( $user_login ).' created an account on the website.</p>'.$email_footer
    );
    }
    add_action('new_customer_registered', 'new_customer_registered_send_email_admin');

    My question is: Is it possible to add an ‘Approve’ or ‘Deny’ button/textlink in the email so admin just has to click once to approve?

    Also, on my woocommerce registration page I have required fields for firstname, lastname, telephone and company. How do I include this information on the admin email along with their email address?

    Thanks,

    Chris.

    https://wordpress.org/plugins/new-user-approve/

Viewing 1 replies (of 1 total)
  • Since this has to do with the woocommerce plugin, I would post this same question in their forum. I’m sure you’ll find more help there.

Viewing 1 replies (of 1 total)

The topic ‘Include approval link in email to admin’ is closed to new replies.