Skip to content

Instantly share code, notes, and snippets.

@Farmatique
Last active May 21, 2018 20:14
Show Gist options
  • Save Farmatique/e45972e3c09ebcdff22f3a01736d105c to your computer and use it in GitHub Desktop.
Save Farmatique/e45972e3c09ebcdff22f3a01736d105c to your computer and use it in GitHub Desktop.
Wordpress woocommerce catch change of variation select
$( ".variations_form" ).on( "woocommerce_variation_select_change", function () {
// Fires whenever variation selects are changed
} );
$( ".single_variation_wrap" ).on( "show_variation", function ( event, variation ) {
// Fired when the user selects all the required dropdowns / attributes
// and a final variation is selected / shown
} );
// another trick
$('form.cart').on( 'change', '.variations select', function( event ) {
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment