Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Bruce

    (@ninjateamwp)

    Hi @gohelkunjan ,

    Thanks for using YayMail, could you please send a screenshot showing how the shortcode is being displayed in a real Email? or where it is not working.

    Kind regards,
    -Bruce-

    Thread Starter Kunjan Gohel

    (@gohelkunjan)

    Hi Bruce,

    Could you please check this screenshot

    https://www.awesomescreenshot.com/image/12596982?key=0f9ba46b36a6f49dbc5053e2697b23b7

    But now i have added custom code via functions.php file

    add_action( 'woocommerce_email_after_order_table', 'customer_note_email_after_order_table', 10, 4 );
    function customer_note_email_after_order_table( $order, $sent_to_admin, $plain_text, $email ){
        // Only on some email notifications
        if ( in_array( $email->id, array('new_order', 'customer_on_hold_order', 'customer_processing_order', 'customer_completed_order') ) ) :
    
        // Get customer Order note
        $customer_note = $order->get_customer_note();
    
        // Display the Customer order notes section
        echo '<h2>' . __("Order notes", "woocommerce") . '</h2>
        <div style="margin-bottom: 40px;">
        <table cellspacing="0" cellpadding="0" style="width: 100%; color: #636363; border: 2px solid #e5e5e5;" border="0">
            <tr><td><p>' . $customer_note . '</p></td></tr>
        </table></div>';
    
        endif;
    }

    Its working fine for me.

    Thanks
    Kunjan Gohel

    Plugin Support Bruce

    (@ninjateamwp)

    Hi @gohelkunjan ,

    Glad to know you had a way around it.
    But then, I would like to understand the issue better so that we can provided a proper, general fix.

    Does that shortcode not display the content it supposed to display inside your inbox? Can you send screenshot of how it is working?

    Thank you!

    Kind regards,
    -Bruce-

    Thread Starter Kunjan Gohel

    (@gohelkunjan)

    Hi @bruce

    Please check this order email screenshot.

    https://www.awesomescreenshot.com/image/12597531?key=e630f1314d75a92fa5707e74089c3931

    Thanks
    Kunjan Gohel

    Plugin Support Bruce

    (@ninjateamwp)

    Hi @gohelkunjan ,

    That appears normally, right?

    Thread Starter Kunjan Gohel

    (@gohelkunjan)

    Right

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

The topic ‘Customer Note not working’ is closed to new replies.