Skip to content

Commit

Permalink
Update mfa_totp.php (openemr#6916)
Browse files Browse the repository at this point in the history
* Update mfa_totp.php

On the original version, if you typed your password and pressed <ENTER>, a blank screen would be displayed.  This is because the <Form onsubmit=""> tag had one action, and the submit <Button> had a different onclick="" action.  This change makes it so pressing <ENTER> or clicking the Submit <Button> execute the same code...

* Update mfa_totp.php

Put type="submit" in \<button\>
  • Loading branch information
DrBassman committed Oct 10, 2023
1 parent 780abc8 commit 46e6e39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions interface/usergroup/mfa_totp.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ function docancel() {
<?php
} ?> <div class="row">
<div class="col-sm-12">
<form method='post' class="form-horizontal" action='mfa_totp.php' onsubmit='return top.restoreSession()'>
<form method='post' class="form-horizontal" action='mfa_totp.php' onsubmit="doregister('reg2')">
<input type="hidden" name="csrf_token_form" value="<?php echo attr(CsrfUtils::collectCsrfToken()); ?>" />


Expand Down Expand Up @@ -126,7 +126,7 @@ function docancel() {
</fieldset>
<div class="form-group clearfix">
<div class="col-sm-12 text-left position-override">
<button type="button" class="btn btn-secondary btn-save" value="<?php echo xla('Submit'); ?>" onclick="doregister('reg2')"><?php echo xlt('Submit'); ?></button>
<button type="submit" class="btn btn-secondary btn-save" value="<?php echo xla('Submit'); ?>"><?php echo xlt('Submit'); ?></button>
<button type="button" class="btn btn-link btn-cancel" value="<?php echo xla('Cancel'); ?>" onclick="docancel()" ><?php echo xlt('Cancel'); ?></button>
</div>
</div>
Expand Down

0 comments on commit 46e6e39

Please sign in to comment.