Answers.Body: <p>Change:</p>
  
  <pre><code>{{ errorList(account.getErrors('password')) }} //Current password
  </code></pre>
  
  <p>To:</p>
  
  <pre><code>{{ errorList(account.getErrors('currentPassword')) }} //Current password
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-03T22:01:49.217Z
Answers.LastActivityDate: 2014-11-03T22:01:49.217Z
Answers.UserDisplayName: Brad Bell
Body: <p>In the Setting of an account on front-end I've added the possibility to change the password. Please enter your current password, then the new</p>
  
  <pre><code>&lt;form id="userform" class="" method="post" accept-charset="UTF-8"&gt;
  
      &lt;input type="hidden" name="action" value="users/saveUser"&gt;
      &lt;input type="hidden" name="redirect" value=""&gt;
      &lt;input type="hidden" name="userId" value="{{ user.id }}"&gt;
  
      {% macro errorList(errors) %}
          {% if errors %}
              &lt;div class="errors"&gt;
  
                  {% for error in errors %}
                      &lt;div&gt;{{ error }}&lt;/div&gt;
                  {% endfor %}
              &lt;/div&gt;
          {% endif %}
      {% endmacro %}
  
      &lt;input id="password" type="password" autocomplete="off" name="password" class="input-list password" value=""&gt;
      &lt;input id="newPassword" type="password" autocomplete="off" name="newPassword" class="input-list password" value=""&gt;
  
      {% if account is defined %}
          {{ errorList(account.getErrors('password')) }} //Current password
          {{ errorList(account.getErrors('password')) }}
          {{ errorList(account.getErrors('newPassword')) }} //New password
          {{ errorList(account.getErrors('newPassword')) }}
      {% endif %}
  
      &lt;input type="submit" value="Save" class="input-submit"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Mistakes new password displayed and the error of the current password is not displayed, for example if it is wrong page just reboot and the data will not be saved. How to be</p>
  
Tags: <error-message><password>
Title: Output error of the current password correctly
ThreadText: # Output error of the current password correctly
  
  (Asked by: username_0 on 2014-11-03)
  
  In the Setting of an account on front-end I've added the possibility to change the password. Please enter your current password, then the new
  
  ```
  <form id="userform" class="" method="post" accept-charset="UTF-8">
  
      <input type="hidden" name="action" value="users/saveUser">
      <input type="hidden" name="redirect" value="">
      <input type="hidden" name="userId" value="{{ user.id }}">
  
      {% macro errorList(errors) %}
          {% if errors %}
              <div class="errors">
  
                  {% for error in errors %}
                      <div>{{ error }}</div>
                  {% endfor %}
              </div>
          {% endif %}
      {% endmacro %}
  
      <input id="password" type="password" autocomplete="off" name="password" class="input-list password" value="">
      <input id="newPassword" type="password" autocomplete="off" name="newPassword" class="input-list password" value="">
  
      {% if account is defined %}
          {{ errorList(account.getErrors('password')) }} //Current password
          {{ errorList(account.getErrors('password')) }}
          {{ errorList(account.getErrors('newPassword')) }} //New password
          {{ errorList(account.getErrors('newPassword')) }}
      {% endif %}
  
      <input type="submit" value="Save" class="input-submit">
  </form>
  
  ```
  
  Mistakes new password displayed and the error of the current password is not displayed, for example if it is wrong page just reboot and the data will not be saved. How to be
  
  **Tags:** error-message, password
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2014-11-03. Score: 1 | Accepted answer
  
  Change:
  
  ```
  {{ errorList(account.getErrors('password')) }} //Current password
  
  ```
  
  To:
  
  ```
  {{ errorList(account.getErrors('currentPassword')) }} //Current password
  
  ```
  
  
  ---
  
  