Latest solutions
Latest comments
- @waru-guru@alirs07
Hi there. Good job. you declared the enter_day id in your index.js file as date, but the day input id is day. That's the typeEfrror reason.
HTML:
<input type="number" placeholder="DD" id="day">
JS:const enter_day = document.getElementById("date");
- @Jonathanbees@alirs07
Hi. User can select multiple options, you can fix that by simply adding the name attribute with the same values to the inputs.
To validate if any input is selected I did this: I declared a variable with the value of 0, then with a forEach method check if any input is selected then change the variable value to input value.
Hope that helps you!
Marked as helpful - @Kaushik1210@alirs07
Hey there! your app shows an error message on invalid inputs but still does the calculation.