Change Position Of Variation Options

It’s possible to change the position of the variation options on the product page. Add this code snippet to your child theme’s functions.php file:

/**
 * Move linked variation options.
 */
function iconic_move_linked_variation_options() {
	remove_action( 'woocommerce_single_product_summary', array( 'Iconic_WLV_Product', 'output_linked_variations' ), 25 );
	
	$priority = 10;

	add_action( 'woocommerce_single_product_summary', array( 'Iconic_WLV_Product', 'output_linked_variations' ), $priority );
}

add_action( 'init', 'iconic_move_linked_variation_options' );

Simply change the value of $priority to move the variation options within the product summary. A smaller value, i.e. 0, will move the options up, and a higher value, i.e. 50, will move them down.

WooCommerce Linked Variations

Link a group of WooCommerce products together by attribute; a new way to handle product variations.

Was this helpful?

Please let us know if this article was useful. It is the best way to ensure our documentation is as helpful as possible.