fbpx
Want To Add Extra Images Per Product Variation For Free? Download Now

Variation after add to cart on flatsome theme

amit goyal

Hello

Purchased this variation swatches plugin. Visit the link https://spiced2c.com/product-category/masale/   and you will see that variation swatches are showing after add to cart button.

After updating in the plugin settings still nothing is changing.

I need a solution otherwise asking refund is the only option.

I want the variation swatches to appear before add to cart button. Theme name is Flatsome.

Here’s a temporary login link to access my site

https://spiced2c.com/wp-admin/?wtlwp_token=5338d44d48f4f631e329cf3d77bfb69ef2c2f2fab262eb226e7910ba00d2b1baa97e92481505aa7d3ef9cdf978e8014b4cbb56f5b2bf4f5b04c64068ee9f642d

Please correct the issue.

Thanks

Hakik Zaman

Hi amit,

Thanks for reaching out to us. The flatsome theme removed some standard hooks and added its own hook.

That’s why that option is not working. BTW, I have added the below Snippet using Code Snippets Plugin:

add_action('woo_variation_swatches_pro_archive_page_loaded', function($wvs_pro){
remove_action('woocommerce_init', array( $wvs_pro, 'enable_swatches' ), 1);
}, 10, 1);

add_action('flatsome_product_box_after', function(){
if ( function_exists( 'woo_variation_swatches' ) ){
woo_variation_swatches()->show_archive_page_swatches();
}
});

Please check and let me know if it works.

Note: Don’t forget to clear your cache like- browser cache, caching plugin cache, and server-side cache.

Thank You