summaryrefslogtreecommitdiff
path: root/actions/deleteuser.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/deleteuser.php')
-rw-r--r--actions/deleteuser.php24
1 files changed, 18 insertions, 6 deletions
diff --git a/actions/deleteuser.php b/actions/deleteuser.php
index 4e6b27395..02ded68b3 100644
--- a/actions/deleteuser.php
+++ b/actions/deleteuser.php
@@ -64,14 +64,14 @@ class DeleteuserAction extends ProfileFormAction
assert(!empty($cur)); // checked by parent
if (!$cur->hasRight(Right::DELETEUSER)) {
- $this->clientError(_("You cannot delete users."));
+ $this->clientError(_('You cannot delete users.'));
return false;
}
$this->user = User::staticGet('id', $this->profile->id);
if (empty($this->user)) {
- $this->clientError(_("You can only delete local users."));
+ $this->clientError(_('You can only delete local users.'));
return false;
}
@@ -92,10 +92,10 @@ class DeleteuserAction extends ProfileFormAction
{
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
if ($this->arg('no')) {
- $this->returnToArgs();
+ $this->returnToPrevious();
} elseif ($this->arg('yes')) {
$this->handlePost();
- $this->returnToArgs();
+ $this->returnToPrevious();
} else {
$this->showPage();
}
@@ -147,8 +147,20 @@ class DeleteuserAction extends ProfileFormAction
}
Event::handle('EndDeleteUserForm', array($this, $this->user));
}
- $this->submit('form_action-no', _('No'), 'submit form_action-primary', 'no', _("Do not block this user"));
- $this->submit('form_action-yes', _('Yes'), 'submit form_action-secondary', 'yes', _('Delete this user'));
+ $this->submit('form_action-no',
+ // TRANS: Button label on the delete user form.
+ _m('BUTTON','No'),
+ 'submit form_action-primary',
+ 'no',
+ // TRANS: Submit button title for 'No' when deleting a user.
+ _('Do not block this user'));
+ $this->submit('form_action-yes',
+ // TRANS: Button label on the delete user form.
+ _m('BUTTON','Yes'),
+ 'submit form_action-secondary',
+ 'yes',
+ // TRANS: Submit button title for 'Yes' when deleting a user.
+ _('Delete this user'));
$this->elementEnd('fieldset');
$this->elementEnd('form');
}