Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter leon0021et

    (@leon0021et)

    Yes, I understood the location of file to edit. But actually, I have found that my email templates:

    customer-on-hold-order.php
    customer-processing-order.php
    customer-completed-order.php

    The above 3 templates have the same action coding. The only difference is the message at the email table head like (hello! Your order is processing / hi! Your order is complete etc). The middle to the end part of coding are the same which all have the action:

    woocommerce_email_order_details
    woocommerce_email_order_meta
    woocommerce_email_customer_details
    woocommerce_email_footer

    Although they have the same coding, when testing, the email sent to client is:

    the “Order on-hold email” does NOT show the Purchase Note while the “Order Processing Email” and “Order Complete Email” both show the Purchase Note of the product.

    I realized that it is the action “woocommerce_email_order_details” that displays the order detail table as well as the Purchase Note inside.

    And now, I would like to change my “Order Complete Email” to like the “Order on-hold Email”, which does NOT show the Purchase Note.

    Sorry for being complicated but really need help of that. Thank you!

    Thread Starter leon0021et

    (@leon0021et)

    Thanks for your help. However, if I want the “Purchase note” to be included in the “Order Processing Email” but just not in the “Order Completed Email”, how can I edit for that?

    Now in my email-order-items.php, it is like this in the end of the code:

    if ( $show_purchase_note && is_object( $_product ) && ( $purchase_note = get_post_meta( $_product->id, ‘_purchase_note’, true ) ) ) : ?>
    <tr>
    <td colspan=”3″ style=”text-align:left; vertical-align:middle; border: 1px solid #eee; font-family: ‘Helvetica Neue’, Helvetica, Roboto, Arial, sans-serif;”><?php echo wpautop( do_shortcode( wp_kses_post( $purchase_note ) ) ); ?></td>
    </tr>
    <?php endif; ?>

    <?php endforeach; ?>

Viewing 2 replies - 1 through 2 (of 2 total)