aboutsummaryrefslogtreecommitdiffhomepage
path: root/templates/change_password_form.php
blob: 7a463fdc30b348fa1f644f021a79a75b69e4b230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<form method="post" action="/todo" hx-post="/fragment/changePassword" hx-disabled-elt="find button" hx-swap="outerHTML">
    <div class="row">
        <label for="changePassword-current"><?= __('changePassword.currentPassword') ?></label>
        <input type="password" id="changePassword-current" name="current" autocomplete="off" required
            value="<?= $current ?? '' ?>">
    </div>
    <div class="row">
        <label for="changePassword-new"><?= __('changePassword.newPassword') ?></label>
        <input type="password" id="changePassword-new" name="new" autocomplete="off" required value="<?= $new ?? '' ?>">
    </div>
    <div class="row">
        <label for="changePassword-newRepeat"><?= __('changePassword.newPassword.repeat') ?></label>
        <input type="password" id="changePassword-newRepeat" name="newRepeat" autocomplete="off" required
            value="<?= $newRepeat ?? '' ?>">
    </div>
    <div class="row">
        <button class="primary"><?= __('changePassword.action') ?></button>
    </div>
    <?php if (isset($error)): ?>
        <p class="error"><?= htmlspecialchars($error) ?></p>
    <?php elseif ($success ?? false): ?>
        <span class="temporaryIndicator"><?= __('changePassword.success') ?></span>
    <?php endif; ?>
</form>