• Resolved abhiverma

    (@abhiverma)


    Hi there,
    When someone place the order on my website, It sends the new account email to the customer but It doesnt send any other email after that like Order Invoice, Order Note etc.

    I have enable all these emails and using SMTP to send the email but still having issue, Can you please help me to short out this issue?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hey @abhiverma,

    When you change the order status to processing, on hold, or completed, it will automatically trigger an email notification to the customer with the order details. Plus, you can manually send the order details or invoice from the order action option on the order editing page.

    Please note that, by default, new order notifications are sent to the admin mail, not the customer email.

    If that is not the case for you, then the issue you’re experiencing could be due to a few reasons. One possibility is that the customer’s email server is filtering the notification emails as spam. Please have your customer check their spam or junk email folder. If the emails are there, they should mark them as “not spam” to prevent this from happening in the future.

    Additionally, to troubleshoot email related issues, I encourage you to follow our detailed guide here: https://woocommerce.com/document/email-faq/

    I also suggest running a conflict test to investigate further the issue. More info: https://woo.com/document/how-to-test-for-conflicts/

    Let us know how that goes for you.

    Thread Starter abhiverma

    (@abhiverma)

    Manually it is sending the emails, As I’m dealing with virtual products on website so, I’m changing the order status by the given below hook.

    add_action( 'woocommerce_payment_complete', 'wpdesk_set_completed_for_paid_orders' );
    
    function wpdesk_set_completed_for_paid_orders( $order_id ) {
    
        $order = wc_get_order( $order_id );
        $order->update_status( 'completed' );
        
    }

    Can we sent automatic email to customer regarding complete order as well?

    Hi there,

    Thank you for contacting WooCommerce Plugin Support.

    It seems that you are using a custom code snippet to change the order status to ‘completed’ when the payment is complete. This may be causing a conflict with the default WooCommerce email triggers, which depend on the order status transitions.

    One possible solution is to use the ‘woocommerce_order_status_changed’ hook instead of the ‘woocommerce_payment_complete’ hook. This hook allows you to specify the old and new order statuses, and trigger the email notifications accordingly.

    Alternatively, you can use a plugin like WooCommerce Order Status Manager to create custom order statuses and email notifications. This plugin allows you to customize the order status workflow and the email settings without writing any code.

    I hope this helps you resolve the issue. If you have any further questions or need more assistance, please let me know. You can also check the WooCommerce support documents for more information on how to set up and troubleshoot email notifications:

    https://woo.com/document/configuring-woocommerce-settings/#email-settings

    Thank you for choosing WooCommerce and have a wonderful day! ??

    Thread Starter abhiverma

    (@abhiverma)

    Hi, I tried with this Hook (woocommerce_order_status_changed) but it is also just updating the order status, can you please share the code of the hook that could trigger the order invoice email once the order status get changed to completed?

    Plugin Support Zubair Zahid (woo-hc)

    (@doublezed2)

    Helllo abhiverma

    Thank you for your reply.

    I understand you are asking for a code of the hook that could trigger the order invoice email.

    Please note that custom code is out of the scope of our support.
    I will recommend you hire a web developer who has experience with WooCommerce and custom coding.

    Feel free to contact us again if you have any other questions related to WooCommerce.

    Have a great day!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Emails notifications are not being sent’ is closed to new replies.