JavaScript Conditionals, More...If you have some extra time, try the following exercise:Exercise 3. Email ValidationPrompt the user for their email address. Then check that the email address the user entered is a valid one. Specifically, make sure that the entered string contains the symbol "@" and a "." (a dot), and that its length is sufficient to include a three-character domain after the dot.
You will need to use the Javascript built-in method
The Similarly, myComputer.indexOf("i") would yield the value 3, since i is the 4th character in the string. Also,
and expect it to return the value 9, as the string "Macintosh" is 9 characters long.
Here is a good on-line reference to Javascript, if you'd like to reference
the documentation on the Here is a demo of the page.
Introduction | Syllabus | Assignments | Documentation | Project |