Answer the question
In order to leave comments, you need to log in
Woocommerce: Is it possible to use multiple attribute values in one variation?
Hello.
There is a task for variable goods. And the usual way is quite working, but very long, since there are a lot of options. For example, tree1 can be colored in color1, color2, color3, and tree2 can be colored in color4, color5, color6. Thus, we already have 6 product variations. But the trouble is that we can have about 10-20 trees, and about 20 different colors for each tree. Thus, about 300-400 variations come out. Tin.
Is there a way to add multiple values of the same attribute to one variation. It seems like you choose attributes for variations -> add a variation -> select "Tree1" -> and in this variation, select all the colors for this tree with some checkboxes.
ps sorry if i didn't explain clearly
Answer the question
In order to leave comments, you need to log in
I solved a similar question ... Only I had leather (many types of leather + each skin has a bunch of its own colors + for each type the price changed depending on the circulation, and the photo of the material changed depending on the color) ...
How I solved this problem .. .At first I sawed the wookomers for a long time, but .... About 20 types of material x 40 or more colors (and each material has its own color, i.e. red of one material! = red of another material) = 800 variations ... And also and circulation .... In general, I had to refuse from Woocommerce ... For some reason, it was easier for me, it was understood that the client would order only one product, and, accordingly, I didn’t have to write the functionality of the shopping cart and the checkout page ...
What I've done. First I created a custom post type (let's call it product, let's say)...
It is clear that categories, tags, tags, etc., must also be created .... Then, through ACF, the repeater set the necessary attributes related to each other ... That is, each material had its own colors and runs.. I repeat ,
this is only because the colors of each material were different for me !!!! If they are the same, most likely it can be done much easier!!!
Half the job is done. Then it will create a template type that was applied to the pages (products) I needed. In the product template, I wrote the output of the first repeater (materials). By clicking on the material, an Ajax request is triggered, which received data from the child repeater in functions.php. And then he transferred the processed data to the template and built the display of the remaining switches (color and circulation).
Then the data I needed was transferred to hidden form fields and, after filling in the client's data, they were sent to the right place (a letter with the data to the administrator and the client) ...
Something like this ... I had such an experience, maybe he can help you, or on push the idea..
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question