Commit 389cfaef authored by Krish Moodbidri's avatar Krish Moodbidri
Browse files

1. improved submit button toggle case wrt checkbox value

2. send checkbox value instead of a hardcoded value
parent 16b3fc1c
Pipeline #5339 failed with stage
var check_counter =0;
function check() { function check() {
var submitButton = document.getElementById("submit"); var submitButton = document.getElementById("submit");
if ((check_counter+=1)%2) submitButton.disabled = false; let ckbox = document.getElementById('agree');
else submitButton.disabled = true; submitButton.disabled = !ckbox.checked;
}; };
function displayloading1() { function displayloading1() {
...@@ -20,7 +19,7 @@ function request_account() { ...@@ -20,7 +19,7 @@ function request_account() {
email: document.getElementById("email").value, email: document.getElementById("email").value,
reason: document.getElementById("reason").value, reason: document.getElementById("reason").value,
username: document.getElementById("username").value, username: document.getElementById("username").value,
aup: 1 aup: document.getElementById("agree").checked
}) })
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment