What changes need to be made to the script in order to abort the submission if an invalid e-mail address is entered?

Consider the following code:

When an invalid e-mail address is entered, an alert is displayed to the user, but the form
submission is not interrupted. What changes need to be made to the script in order to abort the
submission if an invalid e-mail address is entered?

Consider the following code:

When an invalid e-mail address is entered, an alert is displayed to the user, but the form
submission is not interrupted. What changes need to be made to the script in order to abort the
submission if an invalid e-mail address is entered?

A.
Add return false after the alert() statement.

B.
Change return to validate in the function call.

C.
Add validate false after the alert() statement.

D.
Remove the return keyword from the function call and put it in front of the alert() statement.

Explanation:



Leave a Reply 0

Your email address will not be published. Required fields are marked *