• Hi,

    As of now we have no way to position the linked variation inside the product if it is on mobile. Is a hook available to change its position?

Viewing 1 replies (of 1 total)
  • Thread Starter thomasstr

    (@thomasstr)

    For anyone wondering about this issue, it can be solved by using the shortcode available in the plugin. If so, remember to set Position to “No (hide it)”.

    This is how I solved it.

    
    <?php
    function show_linked_variations() {
    	echo do_shortcode('[wpclv]');
    }
    
    add_filter('wp_is_mobile', 'app_is_mobile');
    function app_is_mobile($isMobile) {
    	if ($isMobile) {		
              
    add_action('woocommerce_single_product_summary','show_linked_variations', 14);
    	} else {
    	  add_action('woocommerce_single_product_summary','show_linked_variations', 29);
    	}
    }
    
Viewing 1 replies (of 1 total)
  • The topic ‘Position hook change for linked variations’ is closed to new replies.