reset-form.html.twig 956 B

123456789101112131415161718192021222324
  1. {% if uri.param('token') and uri.param('task') %}
  2. <section id="grav-login">
  3. {{ content|raw }}
  4. <form method="post" action="{{ (base_url_relative ~ uri.path)|e }}" classes="{{ form_outer_classes }}">
  5. {% for field in form.fields %}
  6. {% set value = attribute(grav.twig.twig_vars, field.name) is defined ? attribute(grav.twig.twig_vars, field.name) : null %}
  7. {% if field.type %}
  8. <div>
  9. {% include ["forms/fields/#{field.type}/#{field.type}.html.twig", 'forms/fields/text/text.html.twig'] %}
  10. </div>
  11. {% endif %}
  12. {% endfor %}
  13. <div class="form-actions secondary-accent">
  14. <button type="submit" class="button primary" name="task" value="login.reset"><i class="fa fa-key"></i> {{ "PLUGIN_LOGIN.BTN_RESET"|t }}</button>
  15. </div>
  16. {{ nonce_field('reset-form', 'reset-form-nonce')|raw }}
  17. </form>
  18. </section>
  19. {% endif %}