Title: remove action &#8216;load_inventory_template&#8217;
Last modified: October 4, 2021

---

# remove action ‘load_inventory_template’

 *  Resolved [streamworksaudio](https://wordpress.org/support/users/streamworksaudio/)
 * (@streamworksaudio)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/remove-action-load_inventory_template/)
 * Hi, I am working on some custom code to extend Dokan’s functionality, I am trying
   to remove the action ‘load_inventory_template’ from the hook ‘dokan_product_edit_after_main’–
   the standard remove_action code does not work…
 * `remove_action('dokan_product_edit_after_main', 'load_inventory_template' );`
 * Is the function in a class? If so, what is the class name?
 * The code…
 * `remove_all_actions('dokan_product_edit_after_main');`
 * does work, but I just want to remove the inventory panel for the moment.
 * Cheers

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Arif_me](https://wordpress.org/support/users/arif777/)
 * (@arif777)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/remove-action-load_inventory_template/#post-14940252)
 * Hello [@streamworksaudio](https://wordpress.org/support/users/streamworksaudio/),
 * This will not work as basic remove action. Since the action(hook) was added into
   a class. In that case, you have to use the class instance or class name.
 * However, the following code works for me.
 * >     ```
   >     add_action( 'init', 'dokan_remove_inventory_template_action');
   > 
   >     function dokan_remove_inventory_template_action() {
   >     	remove_action( 'dokan_product_edit_after_main', array( 'WeDevs\Dokan\Dashboard\Templates\Products' ,'load_inventory_template'), 5);
   >     }
   >     ```
   > 
 * Cheers!
    -  This reply was modified 4 years, 7 months ago by [Arif_me](https://wordpress.org/support/users/arif777/).
    -  This reply was modified 4 years, 7 months ago by [Arif_me](https://wordpress.org/support/users/arif777/).
 *  Thread Starter [streamworksaudio](https://wordpress.org/support/users/streamworksaudio/)
 * (@streamworksaudio)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/remove-action-load_inventory_template/#post-14941228)
 * Thanks Arif,
 * I will give this a shot. As I mentioned above, I was sure the function was in
   a class, but I couldn’t figure out which class it was in. I tried ‘Products’ 
   by itself and that did not work. I will try ‘WeDevs\Dokan\Dashboard\Templates\
   Products’
 * Cheers!
 *  [Shafinoid](https://wordpress.org/support/users/shafinahmad01/)
 * (@shafinahmad01)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/remove-action-load_inventory_template/#post-14954803)
 * Hello,
    I believe you are doing well,
 * As you haven’t replied for a long, I’m considering that you have got the solution
   and I’m also resolving this topic.
 * But feel free to create another one anytime.
 * Stay Safe 🙂

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘remove action ‘load_inventory_template’’ is closed to new replies.

 * ![](https://ps.w.org/dokan-lite/assets/icon-256x256.gif?rev=3239229)
 * [Dokan: AI Powered WooCommerce Multivendor Marketplace Solution – Build Your Own Amazon, eBay, Etsy](https://wordpress.org/plugins/dokan-lite/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/dokan-lite/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/dokan-lite/)
 * [Active Topics](https://wordpress.org/support/plugin/dokan-lite/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/dokan-lite/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/dokan-lite/reviews/)

 * 3 replies
 * 3 participants
 * Last reply from: [Shafinoid](https://wordpress.org/support/users/shafinahmad01/)
 * Last activity: [4 years, 7 months ago](https://wordpress.org/support/topic/remove-action-load_inventory_template/#post-14954803)
 * Status: resolved