mirror of
https://github.com/renbaoshuo/S2OJ.git
synced 2024-11-22 14:48:41 +00:00
fix: prevent forms submitting multiple times
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
5531233763
commit
e79128ad94
@ -665,7 +665,12 @@ class UOJForm {
|
|||||||
EOD;
|
EOD;
|
||||||
} else {
|
} else {
|
||||||
echo <<<EOD
|
echo <<<EOD
|
||||||
if (ok) $("#button-submit-{$this->form_name}").addClass('disabled');
|
if (ok) {
|
||||||
|
$("#button-submit-{$this->form_name}").addClass('disabled');
|
||||||
|
$(this).submit(function () {
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
}
|
||||||
return ok;
|
return ok;
|
||||||
EOD;
|
EOD;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user