This repository has been archived on 2023-12-29. You can view files and clone it, but cannot push or open issues or pull requests.
dogstats/web/pages/profile/edit_profile.html

39 lines
1.6 KiB
HTML
Raw Normal View History

2023-10-27 12:32:04 +02:00
<div>
2023-10-30 19:27:44 +01:00
<h1>Mein Profil bearbeiten</h1>
2023-10-27 12:32:04 +02:00
2023-10-30 19:27:44 +01:00
<form id="dogeditform" hx-post="/profile/edit" hx-encoding='multipart/form-data' hx-target="#response">
<div>
<label for="firstname">Vorname</label>
<input type="text" value="<?= $user['firstname']; ?>" id="firstname" name="firstname" class="form-control" placeholder="Max">
2023-10-27 12:32:04 +02:00
</div>
2023-10-30 19:27:44 +01:00
<div>
<label for="lastname">Nachname</label>
<input type="text" value="<?= $user['lastname']; ?>" id="lastname" name="lastname" class="form-control" placeholder="Mustermann">
2023-10-27 12:32:04 +02:00
</div>
2023-10-30 19:27:44 +01:00
<div>
<label for="birthday">Geburtstag</label>
<input type="date" value="<?= $user['birthday']; ?>" id="birthday" name="birthday" class="form-control" placeholder="">
2023-10-27 12:32:04 +02:00
</div>
2023-10-30 19:27:44 +01:00
<div>
<label for="email">E-Mail</label>
<input type="text" value="<?= $user['email']; ?>" id="email" name="email" class="form-control" placeholder="max@max.com" disabled>
2023-10-27 12:32:04 +02:00
</div>
2023-10-30 19:27:44 +01:00
<div>
<label for="club">Verein</label>
<input type="text" value="<?= $user['club']; ?>" id="club" name="club" class="form-control" placeholder="Vereinsname">
2023-10-27 12:32:04 +02:00
</div>
2023-10-30 19:27:44 +01:00
<div>
<label for="photo">Photo</label>
2023-10-27 12:32:04 +02:00
<input type="file" accept="image/png, image/jpeg, image/gif" id="photo" name="photo">
</div>
<button type="submit" name="submit" value="true" class="btn btn-primary">Speichern</button>
</form>
<progress id='progress' value='0' max='100'></progress>
<div id="response"></div>
</div>
<script>
htmx.on('#dogeditform', 'htmx:xhr:progress', function(evt) {
htmx.find('#progress').setAttribute('value', evt.detail.loaded/evt.detail.total * 100)
});
</script>