Failure case for not selecting an option now a permanent solution rather than an alert
Signed-off-by: Eoghan Conlon <eoghanconlon73@skynet.ie>
This commit is contained in:
parent
d19fcb9c10
commit
6dc89697e9
1 changed files with 1 additions and 1 deletions
|
@ -29,7 +29,7 @@
|
|||
listener.preventDefault();
|
||||
const option = document.getElementById('options').value.toString();
|
||||
if (option === '') {
|
||||
alert("Need to implement this");
|
||||
document.getElementById('formStatus').innerHTML = "<span style='background-color: red; color: white'>Failure: Please select an option, then try again</span>";
|
||||
} else {
|
||||
const formData = new FormData(formEl);
|
||||
const value = formData.get('value');
|
||||
|
|
Loading…
Reference in a new issue