Dependent Product Variations in Woocommerce

匆匆过客 提交于 2019-12-13 06:14:05

问题


I am implementing dependent product variations in woocommerce. The problem is that the product has to sizes it is available in Large and Small. The Large size has colors available but the small size of product has a transparent look.

I have added two attributes to the product Size and Color. Now what i want to happen is that when the user selects Large size colors should show up but if he chooses small size the color options select should go blank.

Is there any other way then using a no color options in colors select for Small size?


回答1:


Basically you just need to remove the "small" variations with color.

  1. Make sure your color options are ordered after your size options in the attributes section of the product. Make sure you save.
  2. In your color options group create a transparent color.
  3. Remove all variations that include Small and a color except for small and transparent
  4. If a user chooses small, then they will only have an option for transparent

I just did the exact same thing on a site.



来源:https://stackoverflow.com/questions/17630229/dependent-product-variations-in-woocommerce

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!