app/Plugin/ReCaptcha/Resource/template/default/Contact/recaptcha_contact.twig line 1

Open in your IDE?
  1. {% if show_grecaptcha_badge == false %}
  2.     {% block stylesheet %}
  3.         <style>
  4.             .grecaptcha-badge {
  5.                 visibility: hidden;
  6.             }
  7.         </style>
  8.     {% endblock stylesheet %}
  9. {% endif %}
  10. {% block javascript %}
  11. <script src="https://www.google.com/recaptcha/api.js?render={{ recaptcha_site_key }}"></script>
  12. <script>
  13.     grecaptcha.ready(function () {
  14.         grecaptcha.execute('{{ recaptcha_site_key }}', { action: 'contact' }).then(function (token) {
  15.             var recaptchaResponse = document.getElementById('contact_recaptcha');
  16.             recaptchaResponse.value = token;
  17.         });
  18.         $('#recaptcha_mode').insertAfter('#contact_recaptcha');
  19.     });
  20. </script>
  21. {% endblock javascript %}