Multi Vendor Marketplace Plugin | WCFM Marketplace › Forums › WCFM – Marketplace (WooCommerce Multivendor Marketplace) › Add number to vendor new order mail
- This topic has 3 replies, 2 voices, and was last updated 4 years, 10 months ago by
Sarmistha Chakraborty.
- AuthorPosts
- April 15, 2020 at 2:15 am #119191
guidomagaldi
ParticipantHello, is there a code to put to new order mails so that cient number appears on it???
thanks I am loving your multivendor platform, will eventually move to premium version when my site generate some income!
- April 15, 2020 at 12:18 pm #119283
Sarmistha Chakraborty
MemberHello,
Thanks for get in touch here.
Add this code to your child theme’s functions.php
In case you do not have child theme then add code using this plugin – https://wordpress.org/plugins/code-snippets/add_filter('wcfm_is_allow_wc_default_email_customer_details','__return_true'); add_action('woocommerce_email_customer_details','wcfm_custom_info_customer', 9, 3 ); function wcfm_custom_info_customer( $order, $sent_to_admin = false, $plain_text = false ) { if ( ! is_a( $order, 'WC_Order' ) ) { return; } $customer_id = $order->get_customer_id(); //print your customer/client number }
Thanks.
- April 20, 2020 at 8:03 am #120764
guidomagaldi
Participantthanks!!! and what about adding purchase notes to vendors new order emails, is that possible?
- April 20, 2020 at 3:27 pm #120931
Sarmistha Chakraborty
MemberHi,
you can find the order note using,
echo wp_kses_post( nl2br( wptexturize( $order->get_customer_note() ) ) );
Add this code after your client number.Thanks.
- AuthorPosts
- You must be logged in to reply to this topic.