• Hi guys,
    wondering if I could get some pointers on how to pass/get data to/from the data-product_variations attr form in Product Single pages. I am working on some interactions with the product gallery images and the product variations.

    Basically, I need to be able to trigger stuff on woocommerce_variation_has_changed event.

    I’ve been able to pass and get my data attributes while hooking to single_product_large_thumbnail_size and woocommerce_single_product_image_thumbnail_html.

    But I haven’t been able to pass/get that data during the woocommerce_variation_has_changed event. What I have understood is that the woocommerce_variation_has_changed trigger gets its data from the data-product_variations to insert the product variation related image markup.

    Summing it up, how would I go to add data attr’s to the data-product_variations object? And what would be the best way to get that data during the woocommerce_variation_has_changed event?

    Cheers lads!

    • This topic was modified 7 years, 4 months ago by ameraz.
    • This topic was modified 7 years, 4 months ago by ameraz.
    • This topic was modified 7 years, 4 months ago by ameraz.
  • The topic ‘How to pass/get data to/from data-product_variations object?’ is closed to new replies.