re-order page elements so the show button renders near the top of the page, not at the very bottom

This commit is contained in:
David Goodwin committed 2026-09-21 09:05:34 +01:00
1 parent 9babefd160
commit f73f4de75d
1 file changed
+23 -23
+23 -23
View File
@@ -1,5 +1,28 @@
<form name="password" method="post" action="" class="form-horizontal">
{if $show_form == 'hidden'}
<div id="showform" class="card">
<div class="card-footer">
<div class="btn-toolbar" role="toolbar">
<div class="float-start">
<h3>{$PALANG.TOTP_already_configured}</h3>
</div>
<div class="float-end">
<a href="#" class="btn ml btn-lg btn-primary" id="showbutton">{$PALANG.show}</a>
</div>
</div>
</div>
</div>
<script>
document.getElementById("showbutton").addEventListener("click", function (e) {
showform()
});
function showform() {
document.getElementById("showform").style.visibility = "hidden";
document.getElementById("edit_form").style.visibility = "visible";
}
</script>
{/if}
<div id="edit_form" class="card" style="visibility:{$show_form}">
<div class="card-header"><h4>{$PALANG.pTOTP_welcome}</h4></div>
<div class="card-body enable-asterisk">
@@ -49,28 +72,5 @@
</div>
</div>
</div>
{if $show_form == 'hidden'}
<div id="showform" class="card">
<div class="card-footer">
<div class="btn-toolbar" role="toolbar">
<div class="float-start">
<h3>{$PALANG.TOTP_already_configured}</h3>
</div>
<div class="float-end">
<a href="#" class="btn ml btn-lg btn-primary" id="showbutton">{$PALANG.show}</a>
</div>
</div>
</div>
</div>
<script>
document.getElementById("showbutton").addEventListener("click", function (e) {
showform()
});
function showform() {
document.getElementById("showform").style.visibility = "hidden";
document.getElementById("edit_form").style.visibility = "visible";
}
</script>
{/if}
</form>