Okay
  Public Ticket #3591936
Query regarding masking/hiding of vendor names and details on the marketplace
Closed

Comments

  •  2
    Souk started the conversation

    I am planning to buy marketking multivendor market place plugin. However, I need to know if there is an option to mask/hide the vendors. I do not want to show the names and details of the vendors selling their products to end customers. The vendor name should not be visible to end customers. Is this possible to do? I could not find anything in the setting and wanted to know this. 

    1. https://demomk.wpbay.co/wp-admin/admin.php?page=marketking_vendors

    2. https://demomk.wpbay.co/wp-admin/user-edit.php?user_id=3#marketking_user_vendor_profile

  •  2,217
    WebWizards replied

    Hi there,

    Thank you for getting in touch,


    There is no built in feature for this in the plugin. However, I believe you can hide the vendor details on the site frontend, by adding the following PHP code snippet to your site:

    add_filter('marketking_show_vendor_product_page','__return_false');
    global $marketking_public;
    global $marketkingpro_public;
    remove_filter( 'woocommerce_my_account_my_orders_columns', array($marketking_public, 'marketking_orders_vendor_column') );
    remove_action('b2bking_before_offer_add_to_cart_public', array($marketkingpro_public,'add_vendor_offers_public'));
    remove_filter( 'woocommerce_get_item_data', [$marketking_public,'marketking_show_vendor_cart'], 10, 2 );
    remove_filter('wc_get_template', [$marketking_public, 'marketking_template_orderdetails'], 10, 5);
    remove_filter('wc_get_template', [$marketking_public, 'marketking_template_order_received'], 10, 5);
    add_action('plugins_loaded', function(){
        add_filter('marketking_show_vendor_product_page','__return_false');
        global $marketking_public;
        global $marketkingpro_public;
        remove_filter( 'woocommerce_my_account_my_orders_columns', array($marketking_public, 'marketking_orders_vendor_column') );
        remove_action('b2bking_before_offer_add_to_cart_public', array($marketkingpro_public,'add_vendor_offers_public'));
        remove_filter( 'woocommerce_get_item_data', [$marketking_public,'marketking_show_vendor_cart'], 10, 2 );
        remove_filter('wc_get_template', [$marketking_public, 'marketking_template_orderdetails'], 10, 5);
        remove_filter('wc_get_template', [$marketking_public, 'marketking_template_order_received'], 10, 5);
    });
    

    This should hide it in most places such as the product page, cart, orders, etc.

    This snippet be added to functions.php, or by following our guide here: https://woocommerce-b2b-plugin.com/docs/how-to-add-a-snippet-php-or-js/


    Kind regards,

    Stefan

  •  2
    Souk replied

    Thanks much for your revert. Appreciate it!!

    I have some follow up questions below:

    1. I am building a WordPress website, will these PHP codes (which you provided) work in the word press website version as well? 

    2. Will these codes which you provided, also disable the chat options between the vendor and end customer? Or Is there a separate code for this?

    Thanks much in advance!!

  •  2,217
    WebWizards replied

    Hi again,

    Glad if I can be of help,


    1. I am building a WordPress website, will these PHP codes (which you provided) work in the word press website version as well? 

    Our plugin only works with WordPress. Yes, this code is supposed to be added to the wordpress child theme functions.php file.

    It can also be added to a code snippets plugin: https://woocommerce-b2b-plugin.com/docs/how-to-add-a-snippet-php-or-js/



    2. Will these codes which you provided, also disable the chat options between the vendor and end customer? Or Is there a separate code for this?

    The chat can be disabled in plugin settings. To do it, go to MarketKing -> Modules and disable the modules for: "Messaging" and "Product & Vendor Inquiries".

    Kind regards,

    Stefan