{% extends "base.html" %}
{% load i18n %}

{% block title %}{{ validlink|yesno:"Enter new password,Password reset unsuccessful" }}{% endblock %}
{% block header_content %}{{ validlink|yesno:"Enter new password,Password reset unsuccessful" }}{% endblock %}

{% block content %}
{% if validlink %}
<form action="" method="post">{% csrf_token %}
  <fieldset>
    <p class="lead">{% trans "Please enter your new password twice so we can verify you typed it in correctly." %}</p>
    <div class="form-group">
      <label for="id_new_password1" class="required">{% trans 'New password' %}</label>
      {{ form.new_password1 }}
      <br />
      {{ form.new_password1.errors }}
    </div>
    <div class="form-group">
      <label for="id_new_password2" class="required">{% trans 'Password (again)' %}</label>
      {{ form.new_password2 }}
      <br />
      {{ form.new_password2.errors }}
      <p class="help_text">{% trans 'Enter the same password as above, for verification.' %}</p>
    </div>
  </fieldset>
  <input type="submit" value="{% trans 'Reset my password' %}" class="btn btn-primary" />
</form>
{% else %}
<p class="lead">{% trans "The password reset link was invalid, possibly because it has already been used or has expired. Please request a new <a class='blue' href='/auth/password_reset/'>password reset</a>." %}</p>
{% endif %}
{% endblock %}
