How to change default variation of a product using URL parameters?
-
In WooCommerce, I can select the default variation that appears when a product is viewed using this option (https://i.imgur.com/G6jmujZ.png).
Is it possible to change the default variation using URL parameters?
My wordpress plugin picks up (ie. adds to cart) the default variation automatically so the intention here is to be able to change the default variations so that the correct product gets added to cart by default.
I am aware of the following solutions. However, they do not change the default variation.
1) Linking directly to the product variation: https://stackoverflow.com/questions/33202678/woocommerce-how-to-link-to-product-variation
2) Adding a product variation to cart using URL:
https://www.businessbloomer.com/woocommerce-custom-add-cart-urls-ultimate-guide/Thanks.
- The topic ‘How to change default variation of a product using URL parameters?’ is closed to new replies.