Hey, I’m looking to create 3 product options on Checkout that have different amount of my product in each. And based on the products they get, I need them to be able to pick variants for each: color and sizes. Like this:
I know you need to make Dynamic Variants through something like this:
But the support said I need JS code to make it work.
You will then duplicate the same Form Element 3 times (because we will do 3 products in this example), the only thing you need to change is the Data Name (change the others to “pair2_size”, “pair3_size”…).
Finally, add three more form Elements for the Color variants (the data name should be something like this pair2_color).
2 - Adding the Custom JS code:
Go to Custom Codes > Custom JS(Body), and paste the following code:
So the “pair” refers to product number right. So pair1_size and pair1_color go together to refer to first product option. pair2_size and pair2_color refer to 2nd product option and so on correct?
Hi, i embedded the code below and it only shows the first dropdown field when i select the different radio buttons in my product list. It seems like the code is not connected to the product list variants. Any idea on how to fix it?
To clarify: I have one product and 3 different bundle options in my product list (1x, 2x and 3x) and the product comes in sizes XS,S,M,L and XL. The data name for the “select” form element are set to “pair1_size”, “pair2_size” and “pair3_size”.
@fathx@Bartosz when trying to connect it to shopify variants. I can’t see my variants of funnelish custom code. Do you have any idea or tutorial to make it works ?
How to connect the variants from the code with shopify variants? anyone has an idea ?
Thanks