About

Hey there! We're WC Vendors, the team behind the best WooCommerce multi vendor marketplace plugin.

You can find lots of code snippets on our profile here at WP Code that will enhance your marketplace with some of the less commonly asked for features we have generated installable code snippets for.

If you find a bug in one of these snippets please let us know via the support form on our site :)

And visit us if you're looking for a great multi vendor plugin for WooCommerce!

173 Snippets
10+ Favourites
20+ Downloads

Use Full Store Address in Ships From

add_filter( 'wcv_product_ships_from', 'ships_from_address' ); function ships_from_address( $field ){ global $post, $product; $shipping_disabled = wc_string_to_bool( get_option( 'wcvendors_shipping_management_cap',…

Remove Method label

add_filter( 'woocommerce_cart_shipping_method_full_label', 'remove_shipping_method_title', 10, 2 ); function remove_shipping_method_title( $label, $method ){ $new_label = ''; if (…

Make All Users Vendors

/** * Make all new user registrations Vendors. */ add_filter( 'woocommerce_new_customer_data', 'wcv_woocommerce_new_user_data' ); function wcv_woocommerce_new_user_data( $data…

Show and Save Custom Taxonomy On the Vendor Product Edit Form

This code snippet is for displaying and saving the custom product taxonomy (e.g., "product_brand" or "sizes")…

Add CSS classes to apply for vendor label

/** * Add CSS class to apply for vendor label in a registration * * @param…

How to Set a Default Country on the Vendor Registration Form

Make sure to select the correct vendor registration page under WC Vendors > Settings > Registration…

Single Vendor Purchase

Limits the customers purchase to a single vendor

Add menu item to vendor dashboard

// Add this to your themes functions.php function add_menu_item( $pages ){ $pages[] = array( 'label' =>…

Move "Ships From" under the Product Meta, in the single product page template

Move "Ships From" under the Product Meta, in the single product page template by using 'product_ships_from'…

WC Vendors - Show the "AI" overlay on the product image

// Add an "AI used" checkbox to the vendor's own product edit form, after Tax Class…

Change Method Label

add_filter( 'woocommerce_cart_shipping_method_full_label', 'wcv_override_vendor_shipping_label', 10, 2 ); function wcv_override_vendor_shipping_label( $label, $method ){ $label = 'Flat-rate'; // cost;…

Override the commission calculation priority order

/** * Given the provided list of vendor_ids in the vendors array, override the commission to…

1 2 3 4 … 10