Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var list1 = document.getElementById("list1");
- // hardcode the options (who cares, I don't like web dev)
- if ((list1.value !== "Option 1") || (list1.value !== "Option 2") || (list1.value !== "Option 3") || (list1.value !== "Option 4") || (list1.value !== "Option 5"))
- {
- alert("Your list must contain predefined options!");
- event.preventDefault();
- }
Advertisement
Add Comment
Please, Sign In to add comment