Edit password, improve in UI
This commit is contained in:
parent
d531358810
commit
59346bcc12
|
@ -1,19 +1,29 @@
|
||||||
|
<?php defined('BLUDIT') or die('Bludit CMS.'); ?>
|
||||||
|
|
||||||
|
<?php echo Bootstrap::formOpen(array('id'=>'jsform', 'class'=>'tab-content')); ?>
|
||||||
|
|
||||||
|
<div class="align-middle">
|
||||||
|
<div class="float-right mt-1">
|
||||||
|
<button type="submit" class="btn btn-primary btn-sm" name="save"><?php $L->p('Save') ?></button>
|
||||||
|
<a class="btn btn-secondary btn-sm" href="<?php echo HTML_PATH_ADMIN_ROOT.'edit-user/'.$user->username() ?>" role="button"><?php $L->p('Cancel') ?></a>
|
||||||
|
</div>
|
||||||
|
<?php echo Bootstrap::pageTitle(array('title'=>$L->g('Change password'), 'icon'=>'person')); ?>
|
||||||
|
</div>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
|
// Token CSRF
|
||||||
echo Bootstrap::pageTitle(array('title'=>$L->g('Change password'), 'icon'=>'person'));
|
|
||||||
|
|
||||||
echo Bootstrap::formOpen(array());
|
|
||||||
|
|
||||||
echo Bootstrap::formInputHidden(array(
|
echo Bootstrap::formInputHidden(array(
|
||||||
'name'=>'tokenCSRF',
|
'name'=>'tokenCSRF',
|
||||||
'value'=>$security->getTokenCSRF()
|
'value'=>$security->getTokenCSRF()
|
||||||
));
|
));
|
||||||
|
|
||||||
|
// Username
|
||||||
echo Bootstrap::formInputHidden(array(
|
echo Bootstrap::formInputHidden(array(
|
||||||
'name'=>'username',
|
'name'=>'username',
|
||||||
'value'=>$user->username()
|
'value'=>$user->username()
|
||||||
));
|
));
|
||||||
|
|
||||||
|
// Username disabled
|
||||||
echo Bootstrap::formInputText(array(
|
echo Bootstrap::formInputText(array(
|
||||||
'name'=>'usernameDisabled',
|
'name'=>'usernameDisabled',
|
||||||
'label'=>$L->g('Username'),
|
'label'=>$L->g('Username'),
|
||||||
|
@ -24,6 +34,7 @@ echo Bootstrap::formOpen(array());
|
||||||
'tip'=>''
|
'tip'=>''
|
||||||
));
|
));
|
||||||
|
|
||||||
|
// New password
|
||||||
echo Bootstrap::formInputText(array(
|
echo Bootstrap::formInputText(array(
|
||||||
'name'=>'newPassword',
|
'name'=>'newPassword',
|
||||||
'label'=>$L->g('New password'),
|
'label'=>$L->g('New password'),
|
||||||
|
@ -34,6 +45,7 @@ echo Bootstrap::formOpen(array());
|
||||||
'tip'=>''
|
'tip'=>''
|
||||||
));
|
));
|
||||||
|
|
||||||
|
// Confirm password
|
||||||
echo Bootstrap::formInputText(array(
|
echo Bootstrap::formInputText(array(
|
||||||
'name'=>'confirmPassword',
|
'name'=>'confirmPassword',
|
||||||
'label'=>$L->g('Confirm new password'),
|
'label'=>$L->g('Confirm new password'),
|
||||||
|
@ -43,14 +55,6 @@ echo Bootstrap::formOpen(array());
|
||||||
'placeholder'=>'',
|
'placeholder'=>'',
|
||||||
'tip'=>''
|
'tip'=>''
|
||||||
));
|
));
|
||||||
|
|
||||||
echo '
|
|
||||||
<div class="form-group mt-4">
|
|
||||||
<button type="submit" class="btn btn-primary mr-2" name="save">'.$L->g('Save').'</button>
|
|
||||||
<a class="btn btn-secondary" href="'.HTML_PATH_ADMIN_ROOT.'edit-user/'.$user->username().'#security" role="button">'.$L->g('Cancel').'</a>
|
|
||||||
</div>
|
|
||||||
';
|
|
||||||
|
|
||||||
echo Bootstrap::formClose();
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
<?php echo Bootstrap::formClose(); ?>
|
Loading…
Reference in New Issue