1. Home
  2. WC Vendors Marketplace
  3. Code Snippets
  4. Removing “Sold By” on Your Site

Removing “Sold By” on Your Site

To remove the sold by shown on your marketplace you can use the following code snippet.

/* Remove sold by in product loops */
remove_action( 'woocommerce_after_shop_loop_item', array('WCV_Vendor_Shop', 'template_loop_sold_by'), 9, 2);
/* Remove sold by in cart view */
remove_filter( 'woocommerce_get_item_data', array( 'WCV_Vendor_Cart', 'sold_by' ), 10, 2 );
/* Remove sold by on single product pages */
remove_action( 'woocommerce_product_meta_start', array( 'WCV_Vendor_Cart', 'sold_by_meta' ), 10, 2 );
/* Remove sold by in emails */
remove_filter( 'woocommerce_order_product_title', array( 'WCV_Emails', 'show_vendor_in_email' ), 10, 2 );
/* Remove the entire seller info tab */
remove_filter( 'woocommerce_product_tabs', array( 'WCV_Vendor_Shop', 'seller_info_tab' ) );
/* Remove from order item meta (required to remove if removing from emails too) */
remove_action( 'woocommerce_add_order_item_meta', array('WCV_Vendor_Shop', 'add_vendor_to_order_item_meta'), 10, 2 );

 

Updated on November 10, 2016

Was this article helpful?