Guest User

Untitled

a guest
Dec 18th, 2017
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. function local_pickup_extra_content_email($order, $is_admin_email) {
  2. if ( $is_admin_email ) {
  3. return;
  4. }
  5.  
  6. if ( ICL_LANGUAGE_CODE == "he" && strpos( $order->get_shipping_method(), 'Local Pickup' ) !== false) {
  7. echo '<p><strong>Note:</strong> Please wait for telephone confirmation of local pickup.</p>';
  8. }
  9. }
  10.  
  11. add_action( 'woocommerce_email_after_order_table', 'local_pickup_extra_content_email', 10, 2 );
  12.  
  13. add_action( 'woocommerce_email_after_order_table', 'local_pickup_extra_content_email', 10, 4 );
  14. function local_pickup_extra_content_email( $order, $sent_to_admin, $plain_text, $email ) {
  15. // Only for "Processing Order" and "Order Completed" customer emails
  16. if( ! ( 'customer_processing_order' == $email->id || 'customer_completed_order' == $email->id ) ) return;
  17.  
  18. if ( ICL_LANGUAGE_CODE == "he" && strpos( $order->get_shipping_method(), 'Local Pickup' ) !== false) {
  19. echo '<p><strong>Note:</strong> Please wait for telephone confirmation of local pickup.</p>';
  20. }
  21. }
Add Comment
Please, Sign In to add comment