• Resolved msdesignfoto

    (@msdesignfoto)


    Hello

    The online store I’m working on has a few automated payment methods like credit card, ATM reference and mbway. All these change the order status when the client fullfill the payment. WooCommerce default mode is to send an email to the client when such status change happens in the order. But how can the admin / store manager know when these payments are made? Keeping the orders page open 24/7 and refresh the view is not a solution.

    How can we make the store send to the admin adress, the same email that is sent to the client when an order changes from “on hold” to “processing”?

    Within WooCommerce, by code (I have the snippets plugin) or with third-party plugins.

    Thanks

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Hello @msdesignfoto ,

    Okay, if I understand correctly you want to get the order status change emails to the admin’s email address. Is that right?

    By default WooCommerce only sends these emails to the customer. With some custom code, you can add a CC or BCC to these emails and get the same email to any email address. Here are some example code to achieve such results –

    https://www.businessbloomer.com/woocommerce-add-to-cc-bcc-order-email-recipients/

    I hope this helps.

    Thank you 🙂

    Thread Starter msdesignfoto

    (@msdesignfoto)

    Hello!

    It would be something like that, yes. I need to send an extra email to the admin.

    Now, I just need a different filter type. That page has examples when the order is completed. I need to set the filter to when the order changes to “Processing” and I can’t do it without a bit of help :/ I can implement the code into the snippets and even change a few variables, but to completely replace the filter without knowing how the new filter looks like, its a bit too much for me.

    The rest is basically the same.

    • This reply was modified 3 years, 1 month ago by msdesignfoto.

    Hello @msdesignfoto ,

    Okay, let me help you through this.

    In the same article, I shared they mentioned –

    Note – to target other WooCommerce order emails see here to find the “EMAIL_ID”: https://businessbloomer.com/woocommerce-add-extra-content-order-email/ and then change the filter in the snippet below to “woocommerce_email_recipient_EMAIL_ID“.

    From the given link, we can see that for processing order we need to replace –
    woocommerce_email_recipient_customer_completed_order to woocommerce_email_recipient_customer_processing_order

    So, the final code that should work for you is like this –

    add_filter( 'woocommerce_email_recipient_customer_processing_order', 'bbloomer_order_processing_email_add_to', 9999, 3 );
     
    function bbloomer_order_processing_email_add_to( $email_recipient, $email_object, $email ) {
       $email_recipient .= ',your@email.com';
       return $email_recipient;
    }

    If you need further help regarding customization, I will recommend taking from a freelance marketplace like Upwork.com. Most of the time, they are extremely skilled and affordable as well.

    Thank you 🙂

    Thread Starter msdesignfoto

    (@msdesignfoto)

    Ok, I placed that code and will test this tomorrow. The person in charge of the admin email is not with me right now, so I will ask them when they can read the admin email.

    Thank you very much for your help!
    (I truly read what you posted earlier but didn’t found the filter I wanted)

    Cheers

    Thread Starter msdesignfoto

    (@msdesignfoto)

    Ok so I just had the confirmation from the shop manager and this code works.

    Thank you very much for your assistance!
    Cheers

    Thread Starter msdesignfoto

    (@msdesignfoto)

    Actually it didn’t work as expected.

    The admin got an email when they manually changed an order to Processing, but not when the orders changed status due to automatic payments.

    I’ve tried a few different codes but none seem to work. Maybe there is a plugin that does the job?

    Cheers

    • This reply was modified 3 years, 1 month ago by msdesignfoto.

    Olá @msdesignfoto
    I have the same problem any solution for this?

    Obrigado

    • This reply was modified 2 years, 9 months ago by José.
    Thread Starter msdesignfoto

    (@msdesignfoto)

    Hey José

    I have the email notifications working now, but now I can’t seem to remember how I did it. We still have the code @rur165 provided, and checking this thread, it seems the initial testing was not quite as we expected. However, I can’t find anything else in the WordPress dashboard and settings telling me what method did I use.

    Try this code and let us know if it worked. admin@site.com is the adress where you want to receive the notification emails.

    add_filter( 'woocommerce_email_recipient_customer_processing_order', 'bbloomer_order_processing_email_add_to', 9999, 3 );
     
    function bbloomer_order_processing_email_add_to( $email_recipient, $email_object, $email ) {
       $email_recipient .= ', admin@site.com';
       return $email_recipient;
    }

    Add the Snipets plugin so you can add this code safely, enabling and disabling quickly and without messing around with the site code itself.

    • This reply was modified 2 years, 9 months ago by msdesignfoto.
Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Send email to admin when order status change’ is closed to new replies.