Add number to vendor new order mail

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Viewing 2 reply threads
  • Author
    Posts
    • #119191
      guidomagaldi
      Participant

      Hello, 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!

    • #119283

      Hello,

      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.

    • #120764
      guidomagaldi
      Participant

      thanks!!! and what about adding purchase notes to vendors new order emails, is that possible?

      • #120931

        Hi,

        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.

Viewing 2 reply threads
  • You must be logged in to reply to this topic.