WC Lovers

WooCommerce Frontend Manager - Multivendor marketplace vendor dashboard

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!

Forum Replies Created

Viewing 1 post (of 1 total)
  • Author
    Posts
  • in reply to: Error "File & Name is required" #123341
    hector
    Participant

    Hi,

    I disabled Virtual and Downloadable with this code:

    // START: Disable Virtual & Downloadable
    // From marketplace
    function disable_virtual_downloadable_support( $general_fields ) {
        if ( isset( $general_fields['is_virtual'] ) )
            unset( $general_fields['is_virtual'] );
        if ( isset( $general_fields['is_downloadable'] ) )
            unset( $general_fields['is_downloadable'] );
        return $general_fields;
    }
    
    add_filter( 'wcfm_product_manage_fields_general', 'disable_virtual_downloadable_support' );
    
    // From general Woocommerce
    add_filter( 'product_type_options', function( $options ) {
     
    	// remove "Virtual" checkbox
    	if( isset( $options[ 'virtual' ] ) ) {
    		unset( $options[ 'virtual' ] );
    	}
     
    	// remove "Downloadable" checkbox
    	if( isset( $options[ 'downloadable' ] ) ) {
    		unset( $options[ 'downloadable' ] );
    	}
     
    	return $options;
     
    } );
Viewing 1 post (of 1 total)