vendor/shopware/storefront/Resources/views/storefront/component/captcha/basicCaptcha.html.twig line 1

Open in your IDE?
  1. {% block component_basic_captcha %}
  2.     {% set basicCaptchaOptions = {
  3.         router: path('frontend.captcha.basic-captcha.load'),
  4.         validate: path('frontend.captcha.basic-captcha.validate'),
  5.         captchaRefreshIconId: '#%s-basic-captcha-content-refresh-icon' | format(formId),
  6.         captchaImageId: '#%s-basic-captcha-content-image' | format(formId),
  7.         basicCaptchaInputId: '#%s-basic-captcha-input' | format(formId),
  8.         basicCaptchaFieldId: '#%s-basic-captcha-field' | format(formId),
  9.         formId: formId,
  10.         preCheck: preCheck,
  11.         preCheckRoute : {
  12.             path: path('frontend.captcha.basic-captcha.validate'),
  13.             token: sw_csrf('frontend.captcha.basic-captcha.validate', {'mode': 'token'})
  14.         }
  15.     } %}
  16.     <div class="{{ formRowClass }} basic-captcha"
  17.          data-basic-captcha="true"
  18.          data-basic-captcha-options='{{ basicCaptchaOptions|json_encode }}'>
  19.         <div class="form-group {% if additionalClass %} {{ additionalClass }}{% else %}col-md-6{% endif %} basic-captcha-content">
  20.             {% block component_basic_captcha_image %}
  21.                 <div class="basic-captcha-content-code">
  22.                     <div class="basic-captcha-content-image" id="{{ formId }}-basic-captcha-content-image"></div>
  23.                     {% block component_basic_captcha_refresh_icon %}
  24.                         <a class="btn btn-outline-primary basic-captcha-content-refresh-icon" id="{{ formId }}-basic-captcha-content-refresh-icon">
  25.                             {% sw_icon 'arrow-switch' %}
  26.                         </a>
  27.                     {% endblock %}
  28.                 </div>
  29.             {% endblock %}
  30.             {% block component_basic_captcha_fields_title_label %}
  31.                 <label class="form-label">
  32.                     {{ "captcha.basicCaptchaLabel"|trans|sw_sanitize }}
  33.                 </label>
  34.             {% endblock %}
  35.             {% if preCheck %}
  36.                 <input id="{{ formId }}-precheck"
  37.                        data-skip-report-validity="true"
  38.                        type="text"
  39.                        name="preCheck"
  40.                        class="d-none"
  41.                        required
  42.                 >
  43.             {% endif %}
  44.             {% sw_include '@Storefront/storefront/component/captcha/basicCaptchaFields.html.twig' %}
  45.         </div>
  46.     </div>
  47. {% endblock %}