Compare commits

..

No commits in common. "ed1e79594140ac630d257031aa38a93bf1e1734e" and "442cd25aa63a76b7e8009915253e53b547c11003" have entirely different histories.

4 changed files with 5 additions and 67 deletions

View File

@ -1,29 +0,0 @@
<?php include dirname(path: __DIR__) . '/_header.html.php'; ?>
<form method="POST">
<label for="nick">Username</label>
<input type="text" name="nick" id="nick" required>
<br>
<label for="password">Password</label>
<input type="password" name="password" id="password" required>
<br>
<label for="first">First</label>
<input type="text" name="first" id="first" required>
<br>
<label for="last">Last</label>
<input type="text" name="last" id="last" required>
<br>
<label for="is-admin">Is Admin</label>
<input type="checkbox" name="is_admin" id="is_admin">
<br>
<!-- maybe later -->
<!-- <input type="hidden" name="_csrf" value="csrf_token" -->
<input type="submit" value="Save">
</form>
<?php include dirname(path: __DIR__) . '/_footer.html.php' ?>

View File

@ -1,10 +1,10 @@
<?php include dirname(path: __DIR__) . '/_header.html.php'; ?> <?php include dirname(path: __DIR__) . '/_header.html.php'; ?>
<form method="POST"> <form method="POST">
<input type="hidden" name="id" value="<?= $editUser->getId() ?>"> <input type="hidden" name="id" value="<?= $user->getId() ?>">
<label for="nick">Username</label> <label for="nick">Username</label>
<input type="text" name="nick" id="nick" value="<?= $editUser->getNick() ?>" required> <input type="text" name="nick" id="nick" value="<?= $user->getNick() ?>">
<br> <br>
<label for="password">Password (leave empty to keep the current one)</label> <label for="password">Password (leave empty to keep the current one)</label>
@ -12,15 +12,15 @@
<br> <br>
<label for="first">First</label> <label for="first">First</label>
<input type="text" name="first" id="first" value="<?= $editUser->getFirst() ?>" required> <input type="text" name="first" id="first" value="<?= $user->getFirst() ?>">
<br> <br>
<label for="last">Last</label> <label for="last">Last</label>
<input type="text" name="last" id="last" value="<?= $editUser->getLast() ?>" required> <input type="text" name="last" id="last" value="<?= $user->getLast() ?>">
<br> <br>
<label for="is-admin">Is Admin</label> <label for="is-admin">Is Admin</label>
<input type="checkbox" name="is_admin" id="is_admin" <?= $editUser->isAdmin()?'checked':'' ?>> <input type="checkbox" name="is-admin" id="is-admin" <?= $user->isAdmin()?'checked':'' ?>>
<br> <br>
<!-- maybe later --> <!-- maybe later -->

View File

@ -1,6 +0,0 @@
<?php include '_header.html.php' ?>
<br>
Welcome to Address Book
<?php include '_footer.html.php' ?>

View File

@ -1,27 +0,0 @@
<?php include dirname(path: __DIR__) . '/_header.html.php'; ?>
<?php if (false): ?>
You need Admin rights to access this area.
<?php else: ?>
<br>
<?php if ($message): ?>
<div class="info">
<?= $message ?>
</div>
<?php endif; ?>
<form method="POST">
<label for="nick">Username</label>
<input type="text" name="nick" id="nick">
<label for="password">Password</label>
<input type="password" name="password" id="password">
<!-- maybe later -->
<!-- <input type="hidden" name="_csrf" value="csrf_token" -->
<input type="submit" value="Login">
</form>
<?php endif; ?>
<?php include dirname(path: __DIR__) . '/_footer.html.php' ?>