X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fprofilesettings.php;h=19fbdbd29336d3d7393a3157b4c8c9d498ba9115;hb=48edbb30231e28b74409e02308f15e38940e5da1;hp=28b1d20f34125fab3b39b60281de0b08458dfeb2;hpb=e25d4683c8999a215f3f8e91e280ff52b8dd2499;p=quix0rs-gnu-social.git diff --git a/actions/profilesettings.php b/actions/profilesettings.php index 28b1d20f34..19fbdbd293 100644 --- a/actions/profilesettings.php +++ b/actions/profilesettings.php @@ -452,4 +452,38 @@ class ProfilesettingsAction extends AccountSettingsAction return $other->id != $user->id; } } + + function showAside() { + $user = common_current_user(); + + $this->elementStart('div', array('id' => 'aside_primary', + 'class' => 'aside')); + $this->elementStart('ul'); + if (Event::handle('StartProfileSettingsActions', array($this))) { + if ($user->hasRight(Right::BACKUPACCOUNT)) { + $this->elementStart('li'); + $this->element('a', + array('href' => common_local_url('backupaccount')), + _('Backup account')); + $this->elementEnd('li'); + } + if ($user->hasRight(Right::DELETEACCOUNT)) { + $this->elementStart('li'); + $this->element('a', + array('href' => common_local_url('deleteaccount')), + _('Delete account')); + $this->elementEnd('li'); + } + if ($user->hasRight(Right::RESTOREACCOUNT)) { + $this->elementStart('li'); + $this->element('a', + array('href' => common_local_url('restoreaccount')), + _('Restore account')); + $this->elementEnd('li'); + } + Event::handle('EndProfileSettingsActions', array($this)); + } + $this->elementEnd('ul'); + $this->elementEnd('div'); + } }