title: Trigger event after change of variation WooCommerce
body: <p>I have a price block for every single product page in the WooCommerce project. Like Cash Price, COD Price, PayPal, Stripe, etc.</p>
  <p><a href="https://i.stack.imgur.com/AXbjz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/AXbjz.png" alt="enter image description here" /></a></p>
  <p>Here what I want is to change this pricing based on the selected variation.
  Ex: I have capacities like 32GB, 64GB, 128GB. So, change this price block based on the selected variation.</p>
  <p>Therefore I tried to add an action where I can trigger the event when variations were added. But I can't see that action is working. This is my action code to trigger when variation is selected and price changes. But I can't see this alert in firing.</p>
  <pre><code>function change_pricing_block() {
      ?&gt;
      &lt;script&gt;
      $( &quot;.variations_form&quot; ).on( &quot;woocommerce_variation_select_change&quot;, function () {
          alert('variation');
      });
      &lt;/script&gt;
      &lt;?php
  }
  add_action( 'wp_footer', 'change_pricing_block' );
  </code></pre>
  <p>Can anybody help me with this?</p>
  <p>Thanks in advance</p>