summaryrefslogtreecommitdiffstats
path: root/web/template/account_delete.php
diff options
context:
space:
mode:
authorLukas Fleischer <archlinux@cryptocrack.de>2014-07-25 11:04:19 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2014-07-25 11:30:33 +0200
commit7df8dc8bcb0989a8543d699a7c667809170a69b3 (patch)
tree3ded7b5d19c0ebea74c943ce8e3bced195f072fb /web/template/account_delete.php
parentf4ee1278e5509c531675828dc8fce78ae1a608b9 (diff)
downloadaur-7df8dc8bcb0989a8543d699a7c667809170a69b3.tar.gz
aur-7df8dc8bcb0989a8543d699a7c667809170a69b3.tar.xz
Add support for deleting user accounts
Users can now delete their own accounts by clicking a link in the account edit form and confirming the deletion on a follow-up page. Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/template/account_delete.php')
-rw-r--r--web/template/account_delete.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/web/template/account_delete.php b/web/template/account_delete.php
new file mode 100644
index 00000000..0d40e5a0
--- /dev/null
+++ b/web/template/account_delete.php
@@ -0,0 +1,22 @@
+<p>
+ <?= __('You can use this form to permanently delete the AUR account %s.', '<strong>' . htmlspecialchars($username) . '</strong>') ?>
+</p>
+<p>
+ <?= __('%sWARNING%s: This action cannot be undone.', '<strong>', '</strong>') ?>
+</p>
+
+<form id="edit-profile-form" action="<?= get_user_uri($username) . 'delete/'; ?>" method="post">
+ <fieldset>
+ <input type="hidden" name="Action" value="<?= $A ?>" />
+ <input type="hidden" name="ID" value="<?= $UID ?>" />
+ <input type="hidden" name="token" value="<?= htmlspecialchars($_COOKIE['AURSID']) ?>" />
+ </fieldset>
+ <fieldset>
+ <p><input type="checkbox" name="confirm_Delete" value="1" />
+ <?= __("Confirm deletion") ?></p>
+
+ <p>
+ <input type="submit" class="button" value="<?= __("Delete") ?>" />
+ </p>
+ </fieldset>
+</form>