I need to configure sending the Yandex Yandex metrics goal when sending a Gravity Forms form using js events. I tried different scripts, none of them worked. Here are some examples:

<script> jQuery(document).on('gform_confirmation_loaded', function(e, form_id){ if(form_id == 132) { yaCounter*******.reachGoal('example'); return true; } }); </script> <script type="text/javascript"> jQuery(document).ready(function() { jQuery('#gform_132 input[type=submit]').click(function () { yaCounter*******.reachGoal('example'); return true; }); }); </script> <script type="text/javascript"> jQuery(document).bind('gform_post_render', function() { yaCounter*******.reachGoal('example'); return true; }); }); </script> 

Proudly powered by WordPress version 4.7.11, jQuery version 1.12.4. I would be grateful for any help or advice.

    0