How do i detect Yith Plugin Updates

Hello

im currently considering moving over from IWP over to mainwp, however ive noticed the Yith plugins are not showing when there are new updates… i presume this is the same the the mai-theme that Yith dont use the standard WP update api… however it would be great to know what i would need to do to work around this.

Alex

Alex

Hi Alex,

thanks for reaching out.

have you tried to use this snippet:

You just need to replace the example slug with correct Yith plugin slug.

1 Like

I’ve tried the following snippet and this still isn’t working. YITH updates will show up in my MainWP dash but only after I’ve went to the site admin and clicked into the Updates panel. Then, when I try to update them from my MainWP dashboard i just get a red X and the plugin doesn’t actually update.

add_filter( 'mainwp_detect_premium_plugins_update', 'sprucely_mainwp_detect_premium_plugins_update', 10 );
function sprucely_mainwp_detect_premium_plugins_update( $premiums ) {
	$premiums = array(
		'yith-quick-order-forms-for-woocommerce/init.php',
		'yith-woocommerce-ajax-search-premium/init.php',
		'yith-woocommerce-bulk-product-editing-premium/init.php',
		'yith-woocommerce-cart-messages-premium/init.php',
		'yith-woocommerce-checkout-manager/init.php',
		'yith-woocommerce-color-label-variations-premium/init.php',
		'yith-woocommerce-customize-myaccount-page/init.php',
		'yith-woocommerce-dynamic-pricing-and-discounts-premium/init.php',
		'yith-woocommerce-gift-cards-premium/init.php',
		'yith-google-product-feed-for-woocommerce-premium/init.php',
		'yith-woocommerce-multi-step-checkout-premium/init.php',
		'yith-woocommerce-pre-order.premium/init.php',
		'yith-woocommerce-product-bundles-premium/init.php',
		'yith-woocommerce-product-sales-countdown-premium/init.php',
		'yith-woocommerce-sequential-order-number-premium/init.php',
		'yith-woocommerce-tab-manager/init.php',
		'yith-woocommerce-wishlist-premium/init.php',
	);
	return $premiums;
}

Hi Isaac,

thanks for getting back to me.

I could be wrong, but I am not sure if those are correct slugs.
Can you please double-check if there are files like:

yith-woocommerce-wishlist-premium/yith-woocommerce-wishlist-premium.php

Hi Bogdan,

init.php is the only relevant php file in the root of the plugin, which is why I selected it. It is the file with the plugin header and version info in the doc block. Here’s a copy of this plugin for testing. Most all their others are similarly structured with the init.php in the plugin root.

Hi Isaac,

thanks for getting back to me.

First, let me say that the Yith products are very specific since they use custom update API and that makes problems. However, I will give my best to find some way to make MainWP Dashboard detect these updates.

Can you please try to use this filter: mainwp_request_update_premium_plugins instead of the one you used above mainwp_detect_premium_plugins_update?

Hi Bogdan,

I appreciate your help on this. These plugins are pretty popular, so I would hope it would provide some broad appeal to announce support for updating them. It’s currently quite a pain to have to manually update these across all my sites.

I tried the different filter and didn’t see any change in behavior (the updates still don’t appear in my MWP Dashboard unless I go to the site an navigate to the updates screen.

Hi Isaac,

thanks for the update.

Would you mind opening a private Help Desk ticket so we can collect some additional information & investigate further?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.